shopify 4.9.1 → 4.9.2

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 (353) hide show
  1. package/dist/analytics-H2ANKZ2S.js +1 -0
  2. package/dist/analytics-Q6HJRPRX.js +1 -0
  3. package/dist/assets/hydrogen/starter/CHANGELOG.md +14 -0
  4. package/dist/assets/hydrogen/starter/package.json +2 -2
  5. package/dist/bootstrap.js +1 -1
  6. package/dist/chunk-246AZCDT.js +1 -0
  7. package/dist/{chunk-NHEUJKAO.js → chunk-2NMICU24.js} +1 -1
  8. package/dist/{chunk-3MEL3WLG.js → chunk-2P5DUPT7.js} +1 -1
  9. package/dist/{chunk-C4QR7Z4N.js → chunk-2R2PKQQV.js} +1 -1
  10. package/dist/{chunk-X6Y3HDXN.js → chunk-2VDCTMLY.js} +1 -1
  11. package/dist/{chunk-NZRQKFUB.js → chunk-2X3HYG4B.js} +1 -1
  12. package/dist/{chunk-SHDGD2WJ.js → chunk-3ATOVFLZ.js} +1 -1
  13. package/dist/{chunk-VWYZCCRE.js → chunk-3E3MCY5O.js} +4 -4
  14. package/dist/{chunk-XY2SSJQD.js → chunk-3EEH3A27.js} +1 -1
  15. package/dist/{chunk-COFGQT76.js → chunk-3F42A3XV.js} +2 -2
  16. package/dist/{chunk-QEF43PR2.js → chunk-3NRGGEGU.js} +1 -1
  17. package/dist/{chunk-W6TPRWEE.js → chunk-3NUQGW57.js} +1 -1
  18. package/dist/{chunk-FJCNEHTH.js → chunk-3U2MYUWG.js} +1 -1
  19. package/dist/{chunk-Z6VWYOKN.js → chunk-3ZL4TDTH.js} +1 -1
  20. package/dist/{chunk-EVQPVO4P.js → chunk-4565O5TG.js} +1 -1
  21. package/dist/{chunk-4AXLWDKW.js → chunk-46U6C6C6.js} +1 -1
  22. package/dist/{chunk-JSGOBMF6.js → chunk-4QEALPWD.js} +1 -1
  23. package/dist/{chunk-3GVSG4S6.js → chunk-4S2WKMLJ.js} +1 -1
  24. package/dist/{chunk-N56BJ3F7.js → chunk-4TF7ER72.js} +1 -1
  25. package/dist/{chunk-7AD5YCLL.js → chunk-525BMYNR.js} +1 -1
  26. package/dist/{chunk-HT2JVMLK.js → chunk-55QTRPZ2.js} +1 -1
  27. package/dist/{chunk-ADIHYUQC.js → chunk-5BO5HCN6.js} +1 -1
  28. package/dist/{chunk-EYB45DUG.js → chunk-5JW2EYSE.js} +1 -1
  29. package/dist/{chunk-ZDRQUKLN.js → chunk-5TQOMAJS.js} +1 -1
  30. package/dist/{chunk-2QV5FHXJ.js → chunk-65I35VBS.js} +1 -1
  31. package/dist/{chunk-3WMFKHIM.js → chunk-6H3HVSO5.js} +1 -1
  32. package/dist/{chunk-C7YSU4R5.js → chunk-6NLGZGYE.js} +1 -1
  33. package/dist/{chunk-5KILOX2V.js → chunk-6SO5GA6P.js} +1 -1
  34. package/dist/{chunk-EDLID4PK.js → chunk-7ARGLS6W.js} +3 -3
  35. package/dist/chunk-7E4MJCVE.js +10 -0
  36. package/dist/{chunk-DUWS6Q7C.js → chunk-7EDXMGBQ.js} +1 -1
  37. package/dist/{chunk-S3J3BYQ3.js → chunk-7GJYJ6DU.js} +1 -1
  38. package/dist/{chunk-I4FS7HYY.js → chunk-7IRPE3M5.js} +1 -1
  39. package/dist/{chunk-S3IDGHAZ.js → chunk-7MMPQMU7.js} +1 -1
  40. package/dist/{chunk-NGQDG4CJ.js → chunk-7ZNR4YL4.js} +1 -1
  41. package/dist/{chunk-LAHZ6FO5.js → chunk-AKP4QAGL.js} +1 -1
  42. package/dist/{chunk-RFB7RXTA.js → chunk-ANHSOQTZ.js} +1 -1
  43. package/dist/{chunk-DREP3FRJ.js → chunk-AVOSD4NV.js} +1 -1
  44. package/dist/{chunk-B4YDR22W.js → chunk-B477XHLZ.js} +1 -1
  45. package/dist/{chunk-2RVMF4QP.js → chunk-BK4VCXDD.js} +1 -1
  46. package/dist/{chunk-55JDA75S.js → chunk-BLBJT7BM.js} +1 -1
  47. package/dist/{chunk-YFR53MWF.js → chunk-BLCR7BXU.js} +1 -1
  48. package/dist/{chunk-HQK6QRXN.js → chunk-BPVXYM6G.js} +1 -1
  49. package/dist/{chunk-OJ7KRWUH.js → chunk-BVR3GF2L.js} +1 -1
  50. package/dist/{chunk-QZDFPNYT.js → chunk-BVVYKX4D.js} +1 -1
  51. package/dist/{chunk-GRKZRK4G.js → chunk-C4GEP3CX.js} +1 -1
  52. package/dist/{chunk-K5KUOPEF.js → chunk-CDIKRQ6M.js} +1 -1
  53. package/dist/{chunk-6WGHVCYY.js → chunk-CGH5Y6XE.js} +1 -1
  54. package/dist/{chunk-F34MAI7X.js → chunk-CHRFYG6W.js} +1 -1
  55. package/dist/{chunk-MIMOKFDI.js → chunk-CNAMKKAK.js} +1 -1
  56. package/dist/{chunk-2TOIR7YQ.js → chunk-D2S566HF.js} +1 -1
  57. package/dist/{chunk-XW33ZO7F.js → chunk-DGOBYP74.js} +1 -1
  58. package/dist/{chunk-ZQKZC2KN.js → chunk-DH5E6NM3.js} +1 -1
  59. package/dist/{chunk-QEEA2KEN.js → chunk-DTGIMRBX.js} +1 -1
  60. package/dist/chunk-DV77BSKW.js +1 -0
  61. package/dist/{chunk-BATQEAGE.js → chunk-E64OFJHF.js} +1 -1
  62. package/dist/{chunk-WGBUSO27.js → chunk-EGJQEKAO.js} +1 -1
  63. package/dist/{chunk-2FHVYY3B.js → chunk-EJY4LA2S.js} +1 -1
  64. package/dist/{chunk-P6ID3ULA.js → chunk-ELJ34WWD.js} +1 -1
  65. package/dist/{chunk-OSA6BKSU.js → chunk-ELQ5NPPB.js} +1 -1
  66. package/dist/{chunk-RDCHRPKV.js → chunk-EMKLN75K.js} +1 -1
  67. package/dist/{chunk-ICFM55ZS.js → chunk-EMRUM6AA.js} +1 -1
  68. package/dist/{chunk-RNXWL6DS.js → chunk-EP5HIGAL.js} +1 -1
  69. package/dist/{chunk-JOEWOCHY.js → chunk-ER7ZTF26.js} +1 -1
  70. package/dist/{chunk-J4SJHG3M.js → chunk-EXKTQF26.js} +1 -1
  71. package/dist/{chunk-CUZQRXTV.js → chunk-EZ5F4ZFY.js} +3 -3
  72. package/dist/{chunk-7WWPAHVE.js → chunk-FICC6IFE.js} +1 -1
  73. package/dist/{chunk-MZJKZLCC.js → chunk-FNKTF2OF.js} +1 -1
  74. package/dist/{chunk-NTFIW3VK.js → chunk-FQKURDZR.js} +1 -1
  75. package/dist/{chunk-7ZONBOEZ.js → chunk-FU4UVINZ.js} +1 -1
  76. package/dist/{chunk-254XYKPN.js → chunk-G627WGIC.js} +2 -2
  77. package/dist/{chunk-FNITLQDL.js → chunk-GPJJA3FX.js} +1 -1
  78. package/dist/{chunk-VY7UGJZK.js → chunk-GS52MX5F.js} +1 -1
  79. package/dist/{chunk-23ITMFUO.js → chunk-HKZ75UKL.js} +1 -1
  80. package/dist/chunk-HVU3D3ZU.js +275 -0
  81. package/dist/{chunk-63GEZEYP.js → chunk-HYC3JXR4.js} +1 -1
  82. package/dist/{chunk-5ZSN73EA.js → chunk-HZJHGHLN.js} +1 -1
  83. package/dist/{chunk-XCXQPV5W.js → chunk-I2LILWDI.js} +1 -1
  84. package/dist/{chunk-JA2QZ635.js → chunk-I3J63RFV.js} +1 -1
  85. package/dist/{chunk-YQZPL4K3.js → chunk-I55L6FOM.js} +1 -1
  86. package/dist/{chunk-JCVQB6MX.js → chunk-IESHPQLC.js} +1 -1
  87. package/dist/{chunk-ET2CGROE.js → chunk-IGE4Y5SE.js} +1 -1
  88. package/dist/{chunk-QNR3U4IO.js → chunk-IJLD5UYC.js} +1 -1
  89. package/dist/{chunk-5I5HKOQU.js → chunk-IOS4IDZ2.js} +1 -1
  90. package/dist/{chunk-7H4IM6PX.js → chunk-IQIUFTR6.js} +1 -1
  91. package/dist/{chunk-NWBAD3AV.js → chunk-J66WAKXN.js} +1 -1
  92. package/dist/{chunk-PTS7J2JO.js → chunk-J7ZG6SO3.js} +1 -1
  93. package/dist/{chunk-YS5RZ6D5.js → chunk-JAX56OYG.js} +1 -1
  94. package/dist/{chunk-NSHKVJST.js → chunk-JAY7AGAG.js} +1 -1
  95. package/dist/{chunk-DUWU7CL7.js → chunk-JCKA3O5A.js} +1 -1
  96. package/dist/{chunk-GPRUQBQX.js → chunk-JCO2SDDR.js} +1 -1
  97. package/dist/{chunk-TOLPNBZK.js → chunk-JFBCE4HN.js} +1 -1
  98. package/dist/{chunk-UJD7OQ3I.js → chunk-JJHJYBPQ.js} +1 -1
  99. package/dist/{chunk-RX27ER4R.js → chunk-JKWB7WTO.js} +1 -1
  100. package/dist/{chunk-VXHLE5UQ.js → chunk-JLGXJHPX.js} +1 -1
  101. package/dist/{chunk-VEIZLSMG.js → chunk-JUCOIXG5.js} +1 -1
  102. package/dist/{chunk-HSTNTHWM.js → chunk-JUVJNIEA.js} +1 -1
  103. package/dist/{chunk-SKK7CPUY.js → chunk-JWDR66AS.js} +1 -1
  104. package/dist/chunk-KOYBR5MV.js +1 -0
  105. package/dist/{chunk-NYNSMHKY.js → chunk-KPNUSDCW.js} +1 -1
  106. package/dist/{chunk-7IS6Q756.js → chunk-KY36HSIB.js} +1 -1
  107. package/dist/{chunk-2NBNVDDA.js → chunk-KYBZ2MBA.js} +1 -1
  108. package/dist/{chunk-GHO2S3W3.js → chunk-LIQSNIB3.js} +1 -1
  109. package/dist/{chunk-OKX6PKAW.js → chunk-LWF4EV22.js} +1 -1
  110. package/dist/{chunk-ON3YXHON.js → chunk-M7QFZQ23.js} +1 -1
  111. package/dist/{chunk-QH5R32AA.js → chunk-MHZSSRHP.js} +1 -1
  112. package/dist/{chunk-YACDI6IK.js → chunk-MIP2Y34N.js} +1 -1
  113. package/dist/{chunk-MEFJND2V.js → chunk-MP5NZL7C.js} +1 -1
  114. package/dist/{chunk-IUUKRTKF.js → chunk-MQZPASSP.js} +1 -1
  115. package/dist/{chunk-3VXXYY6S.js → chunk-MW3HFOPD.js} +1 -1
  116. package/dist/{chunk-JF47WERF.js → chunk-N4AR2B6D.js} +1 -1
  117. package/dist/{chunk-JJ4MYCVU.js → chunk-NDMISEDF.js} +1 -1
  118. package/dist/{chunk-77QYKF34.js → chunk-NLKO2J7T.js} +1 -1
  119. package/dist/{chunk-RRBI2IRE.js → chunk-NS4FUSSK.js} +1 -1
  120. package/dist/{chunk-OVOOQFRY.js → chunk-OCQZ2ULI.js} +1 -1
  121. package/dist/{chunk-LOKVWZD2.js → chunk-OERMQ2FP.js} +2 -2
  122. package/dist/{chunk-WRVB4JCZ.js → chunk-OIQVPTNQ.js} +1 -1
  123. package/dist/{chunk-H3QLPW7Q.js → chunk-OMEWUFUL.js} +1 -1
  124. package/dist/{chunk-JCOQDVEB.js → chunk-OXN2DID2.js} +1 -1
  125. package/dist/{chunk-HKNFZUAM.js → chunk-P2MVR6CG.js} +107 -107
  126. package/dist/{chunk-CKLS5LTU.js → chunk-P6TOIMMF.js} +1 -1
  127. package/dist/{chunk-DYHRCMH6.js → chunk-PFIQR7XS.js} +1 -1
  128. package/dist/{chunk-AKSOCKVF.js → chunk-PG6XEOYF.js} +2 -2
  129. package/dist/{chunk-46IUD46F.js → chunk-PGE4HGLA.js} +1 -1
  130. package/dist/{chunk-3UZYLXCB.js → chunk-PI6FLLDD.js} +1 -1
  131. package/dist/{chunk-HDQXFGYG.js → chunk-PIZDYS7T.js} +60 -60
  132. package/dist/{chunk-WBTR5JZ6.js → chunk-PQCALXSD.js} +1 -1
  133. package/dist/{chunk-WR2MMFJO.js → chunk-PQH4U2XV.js} +1 -1
  134. package/dist/{chunk-TGUAZMI2.js → chunk-PQMKPXFV.js} +1 -1
  135. package/dist/{chunk-GF75CMTJ.js → chunk-PV5C6Q2P.js} +1 -1
  136. package/dist/{chunk-P676C7UT.js → chunk-PYILLIGT.js} +1 -1
  137. package/dist/{chunk-HVOYSAB3.js → chunk-Q26ES5T3.js} +1 -1
  138. package/dist/{chunk-2KBTFKSM.js → chunk-Q4TZD2M6.js} +1 -1
  139. package/dist/{chunk-QF6EH4HX.js → chunk-Q555FV2X.js} +1 -1
  140. package/dist/{chunk-UZTL2UET.js → chunk-Q7PF4VKI.js} +23 -23
  141. package/dist/{chunk-UVSXPMUN.js → chunk-QA2NOPXG.js} +1 -1
  142. package/dist/{chunk-5XO6PAMV.js → chunk-QLHPTMIH.js} +1 -1
  143. package/dist/{chunk-7UV53AU2.js → chunk-QMJZFKKU.js} +1 -1
  144. package/dist/{chunk-HJ3DOUAL.js → chunk-QN6SITWN.js} +1 -1
  145. package/dist/{chunk-STLYSBD5.js → chunk-R43LXE66.js} +1 -1
  146. package/dist/chunk-R6IJRVVM.js +70 -0
  147. package/dist/{chunk-5MJX7RKQ.js → chunk-RAQP66LR.js} +1 -1
  148. package/dist/{chunk-LRKJSNM3.js → chunk-RBPMV3KB.js} +1 -1
  149. package/dist/{chunk-KCHERKZO.js → chunk-RCYQPOJW.js} +88 -88
  150. package/dist/{chunk-VPH2AAHJ.js → chunk-RDO5IWB5.js} +1 -1
  151. package/dist/{chunk-FROK2K3X.js → chunk-RGZCV56L.js} +1 -1
  152. package/dist/{chunk-X3WFHNF5.js → chunk-RW2MONAS.js} +1 -1
  153. package/dist/{chunk-CPKLTBLZ.js → chunk-RY6TZDVV.js} +1 -1
  154. package/dist/{chunk-DEY5P63E.js → chunk-SDHDDNKM.js} +1 -1
  155. package/dist/{chunk-IQ4VOPT7.js → chunk-SHBB5GST.js} +1 -1
  156. package/dist/{chunk-ISIPFEFB.js → chunk-SQIESCOJ.js} +1 -1
  157. package/dist/{chunk-VL3XMULV.js → chunk-SRDKLZ4O.js} +1 -1
  158. package/dist/{chunk-VX2CDHRQ.js → chunk-SWNY3RUM.js} +1 -1
  159. package/dist/{chunk-WR6KP7RT.js → chunk-SYNCIFJ6.js} +1 -1
  160. package/dist/{chunk-DZS4GBQX.js → chunk-SZ2JOXTG.js} +1 -1
  161. package/dist/{chunk-OUSRNKZG.js → chunk-T3JUBPBU.js} +1 -1
  162. package/dist/{chunk-QPCDSJ4J.js → chunk-T6TYF72N.js} +1 -1
  163. package/dist/{chunk-U2WUTGPI.js → chunk-TEASB2WU.js} +1 -1
  164. package/dist/{chunk-3VOMVINB.js → chunk-THW6UDZH.js} +1 -1
  165. package/dist/{chunk-T7BUP75N.js → chunk-TPPBEVNQ.js} +1 -1
  166. package/dist/chunk-TQ7MHGY4.js +1 -0
  167. package/dist/{chunk-LQ7ENG4V.js → chunk-TQ7URMGS.js} +1 -1
  168. package/dist/{chunk-GILHUPUG.js → chunk-TUE67I2F.js} +1 -1
  169. package/dist/{chunk-2AZXDU2R.js → chunk-TWS34WUT.js} +1 -1
  170. package/dist/{chunk-5UDBNXNH.js → chunk-U5L2P36D.js} +1 -1
  171. package/dist/{chunk-IPWU2ALH.js → chunk-UB2LAIXS.js} +1 -1
  172. package/dist/{chunk-2AAHKMPP.js → chunk-UMSO6MOI.js} +1 -1
  173. package/dist/{chunk-33D7HGAI.js → chunk-UOKX3AME.js} +1 -1
  174. package/dist/{chunk-77QKJLBG.js → chunk-UVC3IXM3.js} +1 -1
  175. package/dist/chunk-UWHAOGO4.js +4 -0
  176. package/dist/{chunk-DP7SBNLN.js → chunk-UYRXUGLY.js} +1 -1
  177. package/dist/{chunk-RFDOSK57.js → chunk-VXGXK66W.js} +1 -1
  178. package/dist/{chunk-KVZXRZ7U.js → chunk-VZLEYZLX.js} +1 -1
  179. package/dist/{chunk-AZCPTV4A.js → chunk-W56I6HOT.js} +1 -1
  180. package/dist/{chunk-S6YUSGTF.js → chunk-WINVPFT5.js} +1 -1
  181. package/dist/{chunk-B7Y2LMPU.js → chunk-WNE2MZAZ.js} +1 -1
  182. package/dist/{chunk-TH4D7IGZ.js → chunk-WXT5AKZV.js} +1 -1
  183. package/dist/{chunk-DCSSFNW7.js → chunk-WZEKBD7B.js} +1 -1
  184. package/dist/{chunk-AJOTU26E.js → chunk-X6HLGOIV.js} +1 -1
  185. package/dist/{chunk-JWQBRHVY.js → chunk-XE5QH4D7.js} +1 -1
  186. package/dist/{chunk-KXSUEB4Y.js → chunk-XRJ2GQ24.js} +1 -1
  187. package/dist/{chunk-MDMKTILJ.js → chunk-XTKXBQVA.js} +1 -1
  188. package/dist/{chunk-LEFAUWKH.js → chunk-YIV3CWED.js} +1 -1
  189. package/dist/{chunk-LIB64ZJW.js → chunk-YKYJOUV7.js} +1 -1
  190. package/dist/{chunk-NE32WJR5.js → chunk-YXKMPCFH.js} +1 -1
  191. package/dist/{chunk-5CANB25O.js → chunk-Z57YWHOE.js} +1 -1
  192. package/dist/{chunk-LBBYCPZP.js → chunk-Z5SFLTH6.js} +1 -1
  193. package/dist/{chunk-VEQDI5AB.js → chunk-ZJ4H3XEL.js} +1 -1
  194. package/dist/{chunk-XUJURYN5.js → chunk-ZZ7SOJHH.js} +1 -1
  195. package/dist/cli/commands/app/app-logs/sources.js +1 -1
  196. package/dist/cli/commands/app/build.js +1 -1
  197. package/dist/cli/commands/app/bulk/cancel.js +1 -1
  198. package/dist/cli/commands/app/bulk/execute.js +1 -1
  199. package/dist/cli/commands/app/bulk/status.js +1 -1
  200. package/dist/cli/commands/app/config/link.js +1 -1
  201. package/dist/cli/commands/app/config/pull.js +1 -1
  202. package/dist/cli/commands/app/config/use.js +1 -1
  203. package/dist/cli/commands/app/config/validate.js +1 -1
  204. package/dist/cli/commands/app/demo/watcher.js +1 -1
  205. package/dist/cli/commands/app/deploy.js +1 -1
  206. package/dist/cli/commands/app/dev/clean.js +1 -1
  207. package/dist/cli/commands/app/dev.js +1 -1
  208. package/dist/cli/commands/app/env/pull.js +1 -1
  209. package/dist/cli/commands/app/env/show.js +1 -1
  210. package/dist/cli/commands/app/execute.js +1 -1
  211. package/dist/cli/commands/app/function/build.js +1 -1
  212. package/dist/cli/commands/app/function/info.js +1 -1
  213. package/dist/cli/commands/app/function/replay.js +1 -1
  214. package/dist/cli/commands/app/function/run.js +1 -1
  215. package/dist/cli/commands/app/function/schema.js +1 -1
  216. package/dist/cli/commands/app/function/typegen.js +1 -1
  217. package/dist/cli/commands/app/generate/extension.js +1 -1
  218. package/dist/cli/commands/app/graphiql.js +1 -1
  219. package/dist/cli/commands/app/import/channel-config.js +1 -1
  220. package/dist/cli/commands/app/import/custom-data-definitions.js +1 -1
  221. package/dist/cli/commands/app/import/dashboard-extensions.js +1 -1
  222. package/dist/cli/commands/app/import-custom-data-definitions.js +1 -1
  223. package/dist/cli/commands/app/import-extensions.js +1 -1
  224. package/dist/cli/commands/app/info.js +1 -1
  225. package/dist/cli/commands/app/init.js +1 -1
  226. package/dist/cli/commands/app/logs.js +1 -1
  227. package/dist/cli/commands/app/release.js +1 -1
  228. package/dist/cli/commands/app/security/check.js +1 -1
  229. package/dist/cli/commands/app/security/clean.js +1 -1
  230. package/dist/cli/commands/app/security/instructions.js +1 -1
  231. package/dist/cli/commands/app/security/record.js +1 -1
  232. package/dist/cli/commands/app/security/review.js +1 -1
  233. package/dist/cli/commands/app/subscription-migrations/cancel.js +1 -1
  234. package/dist/cli/commands/app/subscription-migrations/list.js +1 -1
  235. package/dist/cli/commands/app/subscription-migrations/schedule.js +1 -1
  236. package/dist/cli/commands/app/subscription-migrations/status.js +1 -1
  237. package/dist/cli/commands/app/subscription-migrations/unschedule.js +1 -1
  238. package/dist/cli/commands/app/versions/list.js +1 -1
  239. package/dist/cli/commands/app/webhook/trigger.js +1 -1
  240. package/dist/cli/commands/auth/login.js +1 -1
  241. package/dist/cli/commands/auth/logout.js +1 -1
  242. package/dist/cli/commands/cache/clear.js +1 -1
  243. package/dist/cli/commands/config/autoupgrade/off.js +1 -1
  244. package/dist/cli/commands/config/autoupgrade/on.js +1 -1
  245. package/dist/cli/commands/config/autoupgrade/status.js +1 -1
  246. package/dist/cli/commands/debug/command-flags.js +1 -1
  247. package/dist/cli/commands/doc/fetch.js +1 -1
  248. package/dist/cli/commands/doc/search.js +1 -1
  249. package/dist/cli/commands/docs/generate.js +1 -1
  250. package/dist/cli/commands/doctor-release/doctor-release.js +1 -1
  251. package/dist/cli/commands/doctor-release/theme/index.js +1 -1
  252. package/dist/cli/commands/help.js +1 -1
  253. package/dist/cli/commands/kitchen-sink/async.js +1 -1
  254. package/dist/cli/commands/kitchen-sink/index.js +1 -1
  255. package/dist/cli/commands/kitchen-sink/prompts.js +1 -1
  256. package/dist/cli/commands/kitchen-sink/static.js +1 -1
  257. package/dist/cli/commands/notifications/generate.js +1 -1
  258. package/dist/cli/commands/notifications/list.js +1 -1
  259. package/dist/cli/commands/organization/list.js +1 -1
  260. package/dist/cli/commands/search.js +1 -1
  261. package/dist/cli/commands/send-analytics.js +1 -1
  262. package/dist/cli/commands/theme/check.js +1 -1
  263. package/dist/cli/commands/theme/console.js +1 -1
  264. package/dist/cli/commands/theme/delete.js +1 -1
  265. package/dist/cli/commands/theme/dev.js +1 -1
  266. package/dist/cli/commands/theme/duplicate.js +1 -1
  267. package/dist/cli/commands/theme/info.js +1 -1
  268. package/dist/cli/commands/theme/init.js +1 -1
  269. package/dist/cli/commands/theme/language-server.js +1 -1
  270. package/dist/cli/commands/theme/list.js +1 -1
  271. package/dist/cli/commands/theme/metafields/pull.js +1 -1
  272. package/dist/cli/commands/theme/open.js +1 -1
  273. package/dist/cli/commands/theme/package.js +1 -1
  274. package/dist/cli/commands/theme/preview.js +1 -1
  275. package/dist/cli/commands/theme/profile.js +1 -1
  276. package/dist/cli/commands/theme/publish.js +1 -1
  277. package/dist/cli/commands/theme/pull.js +1 -1
  278. package/dist/cli/commands/theme/push.js +1 -1
  279. package/dist/cli/commands/theme/rename.js +1 -1
  280. package/dist/cli/commands/theme/share.js +1 -1
  281. package/dist/cli/commands/upgrade.js +1 -1
  282. package/dist/cli/commands/version.js +1 -1
  283. package/dist/cli/help.js +1 -1
  284. package/dist/{command-json-schema-SU56F3T4.js → command-json-schema-HYYJSZAH.js} +1 -1
  285. package/dist/command-registry.js +1 -1
  286. package/dist/{conf-store-WDYDHG6V.js → conf-store-CDZ5YSQM.js} +1 -1
  287. package/dist/{custom-oclif-loader-CP4XJAPS.js → custom-oclif-loader-NVOK22CJ.js} +1 -1
  288. package/dist/{deprecations-CBSMNYL3.js → deprecations-33DG6ZUL.js} +1 -1
  289. package/dist/dist-DODCXJ2A.js +1 -0
  290. package/dist/dist-YXMAKIFS.js +1 -0
  291. package/dist/environments-KBRQNE4R.js +1 -0
  292. package/dist/{error-LNWX6IWE.js → error-V77H2UYX.js} +1 -1
  293. package/dist/error-handler-JY3ZKE2G.js +1 -0
  294. package/dist/{fs-Y33QBYY5.js → fs-SKH3XZU7.js} +1 -1
  295. package/dist/hooks/did-you-mean.js +1 -1
  296. package/dist/hooks/hydrogen-init.js +1 -1
  297. package/dist/hooks/plugin-plugins.js +1 -1
  298. package/dist/hooks/postrun.js +1 -1
  299. package/dist/hooks/prerun.js +1 -1
  300. package/dist/hooks/public-metadata.js +1 -1
  301. package/dist/hooks/sensitive-metadata.js +1 -1
  302. package/dist/hooks/tunnel-provider.js +1 -1
  303. package/dist/hooks/tunnel-start.js +1 -1
  304. package/dist/index.js +1 -1
  305. package/dist/is-global-2G4BLF7H.js +1 -0
  306. package/dist/{json-error-UR2OILQ6.js → json-error-WSMAL66C.js} +1 -1
  307. package/dist/lib-55QUD4AJ.js +1 -0
  308. package/dist/lib-PH52G55H.js +1 -0
  309. package/dist/lib-TYM5B75S.js +1 -0
  310. package/dist/{local-77XQ4CX3.js → local-G2Z24BHM.js} +1 -1
  311. package/dist/{metadata-BC3BGHRY.js → metadata-Y3RKC4P2.js} +1 -1
  312. package/dist/{morph-42EXMN3K.js → morph-BABFBRSW.js} +1 -1
  313. package/dist/{node-package-manager-6UZUTDCP.js → node-package-manager-A7HTBJKY.js} +1 -1
  314. package/dist/notifications-system-E64OSVXF.js +1 -0
  315. package/dist/os-7VQXVZWF.js +1 -0
  316. package/dist/{output-GGY66WEM.js → output-ZFFHJGNK.js} +1 -1
  317. package/dist/system-ZLITSFDC.js +1 -0
  318. package/dist/tsconfig.tsbuildinfo +1 -1
  319. package/dist/typescript-ISACCMJN.js +1 -0
  320. package/dist/ui-YSFALYSL.js +1 -0
  321. package/dist/upgrade-I4JTR4LA.js +1 -0
  322. package/dist/version-AOVO47AW.js +1 -0
  323. package/dist/version-LQV54JBC.js +1 -0
  324. package/dist/{workerd-MEAM3XYI.js → workerd-RNDPF36Q.js} +1 -1
  325. package/oclif.manifest.json +2 -2
  326. package/package.json +8 -8
  327. package/dist/analytics-EPKJADE2.js +0 -1
  328. package/dist/analytics-TVCGKQGZ.js +0 -1
  329. package/dist/chunk-32B4LIKH.js +0 -1
  330. package/dist/chunk-7UZO72KN.js +0 -278
  331. package/dist/chunk-7Y7AZRL3.js +0 -10
  332. package/dist/chunk-A6OSIGQI.js +0 -1
  333. package/dist/chunk-F3TMLDLC.js +0 -1
  334. package/dist/chunk-MFXBSQDH.js +0 -12
  335. package/dist/chunk-MINDMVTH.js +0 -1
  336. package/dist/chunk-PCKWLJW2.js +0 -1
  337. package/dist/chunk-SMZ74TME.js +0 -64
  338. package/dist/dist-HI6AAP5V.js +0 -1
  339. package/dist/dist-W25ND3PJ.js +0 -1
  340. package/dist/environments-PUH6A5BU.js +0 -1
  341. package/dist/error-handler-24QGAUUD.js +0 -1
  342. package/dist/is-global-KY3QE3OZ.js +0 -1
  343. package/dist/lib-AD2G3QH3.js +0 -1
  344. package/dist/lib-VEVNMHDE.js +0 -1
  345. package/dist/lib-ZQW4E7QU.js +0 -1
  346. package/dist/notifications-system-4UDT72DQ.js +0 -1
  347. package/dist/os-U3LELTCV.js +0 -1
  348. package/dist/system-MCWAHFXK.js +0 -1
  349. package/dist/typescript-5R4Y7PXE.js +0 -1
  350. package/dist/ui-SYB4LLWY.js +0 -1
  351. package/dist/upgrade-V4GCQJBN.js +0 -1
  352. package/dist/version-HQPFW4QN.js +0 -1
  353. package/dist/version-VOSHQCYM.js +0 -1
@@ -1 +1 @@
1
- import{n as A}from"./chunk-LAHZ6FO5.js";import{a as P}from"./chunk-JJ4MYCVU.js";import{c as C}from"./chunk-NZRQKFUB.js";import{s as T}from"./chunk-NSHKVJST.js";import{r as w}from"./chunk-2AZXDU2R.js";import{a as D}from"./chunk-4AXLWDKW.js";import{K as u}from"./chunk-VWYZCCRE.js";import{B as y,z as h}from"./chunk-KCHERKZO.js";import{Nb as O,za as p}from"./chunk-COFGQT76.js";import{d,q as m}from"./chunk-3VYOLEQE.js";import{g as l}from"./chunk-VKWPEFWQ.js";l();async function q(e){P({verbose:e.verbose,noColor:e.noColor});let t=w({store:e.store}),o=await u(t,e.password);await R(o,{path:e.path??m(),force:e.force??!1,silent:e.silent??!1})}var E={article:"ARTICLE",blog:"BLOG",collection:"COLLECTION",company:"COMPANY",company_location:"COMPANY_LOCATION",location:"LOCATION",market:"MARKET",order:"ORDER",page:"PAGE",product:"PRODUCT",variant:"PRODUCTVARIANT",shop:"SHOP"};async function R(e,t){let{force:o,path:i,silent:n}=t;if(!await A(i)&&(process.env.SHOPIFY_LANGUAGE_SERVER==="1"||!await C(o)))return;let f=[],r=[];for(let[a,s]of Object.entries(E))f.push(T(s,e).catch(c=>(r.push(s),[])).then(c=>({[a]:c})));let b=(await Promise.all(f)).reduce((a,s)=>({...a,...s}));if(r.length===Object.values(E).length){n||y({body:"Failed to fetch metafield definitions.",nextSteps:["Check your network connection and try again.","Ensure you have the permission to fetch metafield definitions."],reference:[{link:{label:"Metafield Definition API",url:"https://shopify.dev/docs/api/admin-graphql/latest/queries/metafieldDefinition"}}]});return}await S(i,b),r.length>0&&O(`Failed to fetch metafield definitions for the following owner types: ${r.join(", ")}`),n||h({body:"Metafield definitions have been successfully downloaded."})}async function S(e,t){let o=await D(e),i=d(o,"metafields.json"),n=JSON.stringify(t,null,2);p(i,n)}export{q as a};
1
+ import{n as A}from"./chunk-AKP4QAGL.js";import{a as P}from"./chunk-NDMISEDF.js";import{c as C}from"./chunk-2X3HYG4B.js";import{s as T}from"./chunk-JAY7AGAG.js";import{r as w}from"./chunk-TWS34WUT.js";import{a as D}from"./chunk-46U6C6C6.js";import{K as u}from"./chunk-3E3MCY5O.js";import{B as y,z as h}from"./chunk-RCYQPOJW.js";import{Nb as O,za as p}from"./chunk-3F42A3XV.js";import{d,q as m}from"./chunk-3VYOLEQE.js";import{g as l}from"./chunk-VKWPEFWQ.js";l();async function q(e){P({verbose:e.verbose,noColor:e.noColor});let t=w({store:e.store}),o=await u(t,e.password);await R(o,{path:e.path??m(),force:e.force??!1,silent:e.silent??!1})}var E={article:"ARTICLE",blog:"BLOG",collection:"COLLECTION",company:"COMPANY",company_location:"COMPANY_LOCATION",location:"LOCATION",market:"MARKET",order:"ORDER",page:"PAGE",product:"PRODUCT",variant:"PRODUCTVARIANT",shop:"SHOP"};async function R(e,t){let{force:o,path:i,silent:n}=t;if(!await A(i)&&(process.env.SHOPIFY_LANGUAGE_SERVER==="1"||!await C(o)))return;let f=[],r=[];for(let[a,s]of Object.entries(E))f.push(T(s,e).catch(c=>(r.push(s),[])).then(c=>({[a]:c})));let b=(await Promise.all(f)).reduce((a,s)=>({...a,...s}));if(r.length===Object.values(E).length){n||y({body:"Failed to fetch metafield definitions.",nextSteps:["Check your network connection and try again.","Ensure you have the permission to fetch metafield definitions."],reference:[{link:{label:"Metafield Definition API",url:"https://shopify.dev/docs/api/admin-graphql/latest/queries/metafieldDefinition"}}]});return}await S(i,b),r.length>0&&O(`Failed to fetch metafield definitions for the following owner types: ${r.join(", ")}`),n||h({body:"Metafield definitions have been successfully downloaded."})}async function S(e,t){let o=await D(e),i=d(o,"metafields.json"),n=JSON.stringify(t,null,2);p(i,n)}export{q as a};
@@ -1,4 +1,4 @@
1
- import{a as M}from"./chunk-STLYSBD5.js";import{a as E}from"./chunk-MINDMVTH.js";import{a as I}from"./chunk-RFDOSK57.js";import{Ha as j,I as C}from"./chunk-AKSOCKVF.js";import{e as O}from"./chunk-ZQKZC2KN.js";import{b as z}from"./chunk-LOKVWZD2.js";import{b as R}from"./chunk-2KBTFKSM.js";import{$ as h,N as _,ca as g,u as y}from"./chunk-VWYZCCRE.js";import{H as T,I as k,y as A}from"./chunk-KCHERKZO.js";import{l as D}from"./chunk-XUJURYN5.js";import{Cb as p,Eb as m,Kb as f}from"./chunk-COFGQT76.js";import{b as W}from"./chunk-JA2QZ635.js";import{e as F,g as s}from"./chunk-VKWPEFWQ.js";s();s();s();var L={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metafieldDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"ownerType"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"MetafieldOwnerType"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metafieldDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"ownerType"},value:{kind:"Variable",name:{kind:"Name",value:"ownerType"}}},{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"30"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetafieldForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetafieldForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetafieldDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"namespace"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}},{kind:"Field",name:{kind:"Name",value:"customerAccount"}}]}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"adminFilterable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}}]}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]};s();async function J(e){let i="Admin",n=O(e.storeFqdn,"unstable");return{token:e.token,api:i,url:n}}async function P(e){return g({query:e.query,...await J(e.session),variables:e.variables,autoRateLimitRestore:e.autoRateLimitRestore})}s();var w={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metaobjectDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaobjectDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"10"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetaobjectForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetaobjectForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetaobjectDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"type"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}}]}},{kind:"Field",name:{kind:"Name",value:"displayNameKey"}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publishable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"translatable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"renderable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}},{kind:"Field",name:{kind:"Name",value:"data"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaTitleKey"}},{kind:"Field",name:{kind:"Name",value:"metaDescriptionKey"}}]}}]}}]}},{kind:"Field",name:{kind:"Name",value:"fieldDefinitions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"required"}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]}}]};var x=F(z(),1);var Q={article:"ARTICLE",blog:"BLOG",collection:"COLLECTION",company:"COMPANY",company_location:"COMPANY_LOCATION",location:"LOCATION",market:"MARKET",order:"ORDER",page:"PAGE",product:"PRODUCT",customer:"CUSTOMER",delivery_customization:"DELIVERY_CUSTOMIZATION",delivery_method:"DELIVERY_METHOD",delivery_option_generator:"DELIVERY_OPTION_GENERATOR",discount:"DISCOUNT",draft_order:"DRAFTORDER",fulfillment_constraint_rule:"FULFILLMENT_CONSTRAINT_RULE",gift_card_transaction:"GIFT_CARD_TRANSACTION",order_routing_location_rule:"ORDER_ROUTING_LOCATION_RULE",payment_customization:"PAYMENT_CUSTOMIZATION",selling_plan:"SELLING_PLAN",shop:"SHOP",validation:"VALIDATION",variant:"PRODUCTVARIANT",cart_transform:"CARTTRANSFORM"};async function $({query:e,session:i,toNodes:n,toVariables:t,performQuery:d=a=>P({query:e,session:i,variables:a,autoRateLimitRestore:!0})}){let a;try{let o=n(await d(t(a))),l=[];for(l.push(...o.nodes);o.pageInfo.hasNextPage;)a=o.pageInfo.endCursor,o=n(await d(t(a))),l.push(...o.nodes);return{status:"ok",items:l}}catch(o){if(o instanceof Error&&o.message.includes("ACCESS_DENIED"))return{status:"scope_error"};throw o}}function V(e,i){let n="";for(let t of e)n=(0,x.updateTomlValues)(n,t);return`# ${i}
1
+ import{a as M}from"./chunk-R43LXE66.js";import{a as E}from"./chunk-KOYBR5MV.js";import{a as I}from"./chunk-VXGXK66W.js";import{Ha as j,I as C}from"./chunk-PG6XEOYF.js";import{e as O}from"./chunk-DH5E6NM3.js";import{b as z}from"./chunk-OERMQ2FP.js";import{b as R}from"./chunk-Q4TZD2M6.js";import{$ as h,N as _,ca as g,u as y}from"./chunk-3E3MCY5O.js";import{H as T,I as k,y as A}from"./chunk-RCYQPOJW.js";import{l as D}from"./chunk-ZZ7SOJHH.js";import{Cb as p,Eb as m,Kb as f}from"./chunk-3F42A3XV.js";import{b as W}from"./chunk-I3J63RFV.js";import{e as F,g as s}from"./chunk-VKWPEFWQ.js";s();s();s();var L={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metafieldDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"ownerType"}},type:{kind:"NonNullType",type:{kind:"NamedType",name:{kind:"Name",value:"MetafieldOwnerType"}}}},{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metafieldDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"ownerType"},value:{kind:"Variable",name:{kind:"Name",value:"ownerType"}}},{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"30"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetafieldForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetafieldForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetafieldDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"namespace"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}},{kind:"Field",name:{kind:"Name",value:"customerAccount"}}]}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"adminFilterable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}}]}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]};s();async function J(e){let i="Admin",n=O(e.storeFqdn,"unstable");return{token:e.token,api:i,url:n}}async function P(e){return g({query:e.query,...await J(e.session),variables:e.variables,autoRateLimitRestore:e.autoRateLimitRestore})}s();var w={kind:"Document",definitions:[{kind:"OperationDefinition",operation:"query",name:{kind:"Name",value:"metaobjectDefinitions"},variableDefinitions:[{kind:"VariableDefinition",variable:{kind:"Variable",name:{kind:"Name",value:"after"}},type:{kind:"NamedType",name:{kind:"Name",value:"String"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaobjectDefinitions"},arguments:[{kind:"Argument",name:{kind:"Name",value:"first"},value:{kind:"IntValue",value:"10"}},{kind:"Argument",name:{kind:"Name",value:"after"},value:{kind:"Variable",name:{kind:"Name",value:"after"}}}],selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"pageInfo"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"hasNextPage"}},{kind:"Field",name:{kind:"Name",value:"endCursor"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"nodes"},selectionSet:{kind:"SelectionSet",selections:[{kind:"FragmentSpread",name:{kind:"Name",value:"MetaobjectForImport"}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}},{kind:"Field",name:{kind:"Name",value:"__typename"}}]}}]}},{kind:"FragmentDefinition",name:{kind:"Name",value:"MetaobjectForImport"},typeCondition:{kind:"NamedType",name:{kind:"Name",value:"MetaobjectDefinition"}},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"type"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"access"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"admin"}},{kind:"Field",name:{kind:"Name",value:"storefront"}}]}},{kind:"Field",name:{kind:"Name",value:"displayNameKey"}},{kind:"Field",name:{kind:"Name",value:"capabilities"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"publishable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"translatable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}}]}},{kind:"Field",name:{kind:"Name",value:"renderable"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"enabled"}},{kind:"Field",name:{kind:"Name",value:"data"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"metaTitleKey"}},{kind:"Field",name:{kind:"Name",value:"metaDescriptionKey"}}]}}]}}]}},{kind:"Field",name:{kind:"Name",value:"fieldDefinitions"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"key"}},{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"type"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"category"}},{kind:"Field",name:{kind:"Name",value:"name"}}]}},{kind:"Field",name:{kind:"Name",value:"description"}},{kind:"Field",name:{kind:"Name",value:"required"}},{kind:"Field",name:{kind:"Name",value:"validations"},selectionSet:{kind:"SelectionSet",selections:[{kind:"Field",name:{kind:"Name",value:"name"}},{kind:"Field",name:{kind:"Name",value:"value"}}]}}]}}]}}]};var x=F(z(),1);var Q={article:"ARTICLE",blog:"BLOG",collection:"COLLECTION",company:"COMPANY",company_location:"COMPANY_LOCATION",location:"LOCATION",market:"MARKET",order:"ORDER",page:"PAGE",product:"PRODUCT",customer:"CUSTOMER",delivery_customization:"DELIVERY_CUSTOMIZATION",delivery_method:"DELIVERY_METHOD",delivery_option_generator:"DELIVERY_OPTION_GENERATOR",discount:"DISCOUNT",draft_order:"DRAFTORDER",fulfillment_constraint_rule:"FULFILLMENT_CONSTRAINT_RULE",gift_card_transaction:"GIFT_CARD_TRANSACTION",order_routing_location_rule:"ORDER_ROUTING_LOCATION_RULE",payment_customization:"PAYMENT_CUSTOMIZATION",selling_plan:"SELLING_PLAN",shop:"SHOP",validation:"VALIDATION",variant:"PRODUCTVARIANT",cart_transform:"CARTTRANSFORM"};async function $({query:e,session:i,toNodes:n,toVariables:t,performQuery:d=a=>P({query:e,session:i,variables:a,autoRateLimitRestore:!0})}){let a;try{let o=n(await d(t(a))),l=[];for(l.push(...o.nodes);o.pageInfo.hasNextPage;)a=o.pageInfo.endCursor,o=n(await d(t(a))),l.push(...o.nodes);return{status:"ok",items:l}}catch(o){if(o instanceof Error&&o.message.includes("ACCESS_DENIED"))return{status:"scope_error"};throw o}}function V(e,i){let n="";for(let t of e)n=(0,x.updateTomlValues)(n,t);return`# ${i}
2
2
  ${n}`}function Z(e,i){let n=i.map(oe).map(a=>{switch(a.status){case"ok":{let{typeName:o,patches:l}=a;return V(l,`type: $app:${o}`)}case"not_app_reserved":return null}}).filter(a=>a!==null),t=e.flatMap(({items:a,ownerType:o,graphQLOwner:l})=>a.map(r=>({result:de(r,o),graphQLOwner:l}))).map(({result:a,graphQLOwner:o})=>{switch(a.status){case"ok":{let{namespace:l,key:r,patches:N}=a;return V(N,`namespace: ${l==="app"?"$app":`$app:${l}`} key: ${r} owner_type: ${o}`)}case"not_app_reserved":return null}}).filter(a=>a!==null);return{tomlContent:[...n,...t].join(`
3
3
  `),metafieldCount:t.length,metaobjectCount:n.length}}async function q(e){let i=await ae(e),n=i.storeFqdn,t=await ee(i),d=await ne(i);e.includeExistingDeclaredDefinitions||(t=ie(t,e.appConfiguration),d=te(d,e.appConfiguration));let{tomlContent:a,metafieldCount:o,metaobjectCount:l}=Z(t,d);X(o,l,n,a)}function X(e,i,n,t){A({headline:"Conversion to TOML complete.",body:["Converted",{warn:`${e} metafields`},"and",{warn:`${i} metaobjects`},"from",{warn:n},"into TOML, ready for you to copy."],orderedNextSteps:!0,nextSteps:["Review the suggested TOML carefully before applying.",["Missing sections? Make sure your app has the required access scopes to load metafields and metaobjects (e.g.",{command:"read_customers"},"to load customer metafields,",{command:"read_metaobject_definitions"},"to load metaobjects.)"],["Missing definitions? Only metafields and metaobjects that are app-reserved (using",{command:"$app"},") will be converted."],["When you're ready, add the generated TOML to your app's configuration file and test out changes with the",{command:"shopify app dev"},"command."]]}),ce(t)}async function ee(e){let i=[];return await T(Object.entries(Q).map(([n,t])=>({title:m`Loading ${p.green(n)} metafields`,task:async()=>{let d=await $({query:L,session:e,toNodes:a=>a.metafieldDefinitions,toVariables:a=>({ownerType:t,after:a})});i.push({metafields:d,ownerType:n,graphQLOwner:t})}}))),i.map(({metafields:n,ownerType:t,graphQLOwner:d})=>n.status==="ok"?{ownerType:t,items:n.items,graphQLOwner:d}:null).filter(n=>n!==null)}async function ne(e){let i=await k({title:m`Loading ${p.green("metaobjects")}`,task:async()=>$({query:w,session:e,toNodes:n=>n.metaobjectDefinitions,toVariables:n=>({after:n})})});return i.status==="ok"?i.items:[]}function ie(e,i){return e.map(n=>{let t=n.items.filter(d=>!K(i,[n.ownerType,"metafields",u(d.namespace)??"",d.key]));return t.length>0?{...n,items:t}:null}).filter(n=>n!==null)}function te(e,i){return e.filter(n=>!K(i,["metaobjects","app",u(n.type)??""]))}function K(e,i){let n=e;for(let t of i){if(!n[t])return!1;n=n[t]}return!0}async function ae(e){let{remoteApp:i,store:n}=e,t=i.apiSecretKeys[0]?.secret;if(!t)throw new D("No API secret keys found for app");return await _(n.shopDomain,i.apiKey,t)}function u(e){if(!e.match(/^app--\d+/))return null;let i="app";return e.match(/^app--\d+--/)&&(i=e.replace(/^app--\d+--/,"")),i}function de(e,i){let n=u(e.namespace);if(!n)return{status:"not_app_reserved"};let t=e.key,d=le(e),a=re(d,i,n,t);return{status:"ok",key:t,namespace:n,patches:a}}function oe(e){let i=u(e.type);if(!i)return{status:"not_app_reserved"};let n=se(e,i),t=me(n,i);return{status:"ok",typeName:i,patches:t}}function le(e){let i={name:e.name===e.key?void 0:e.name,type:e.type.name,description:e.description??void 0,capabilities:c({admin_filterable:e.capabilities.adminFilterable.enabled||void 0}),access:c({admin:H(e.access.admin),storefront:Y(e.access.storefront),customer_account:ue(e.access.customerAccount)}),validations:G(e.validations)},{type:n,validations:t}=U(i.type,i.validations);return i.type=n,i.validations=t,i}function se(e,i){return{name:e.name===i?void 0:e.name,description:e.description??void 0,display_name_field:e.displayNameKey??void 0,access:c({admin:H(e.access.admin),storefront:Y(e.access.storefront)}),capabilities:c({translatable:e.capabilities.translatable.enabled||void 0,publishable:e.capabilities.publishable.enabled||void 0,renderable:e.capabilities.renderable?.enabled||void 0,renderable_meta_title_field:e.capabilities.renderable?.data?.metaTitleKey??void 0,renderable_meta_description_field:e.capabilities.renderable?.data?.metaDescriptionKey??void 0}),fields:Object.fromEntries(e.fieldDefinitions.map(n=>{let t={type:n.type.name,description:n.description??void 0,name:n.name===n.key?void 0:n.name,required:n.required||void 0,validations:G(n.validations)},{type:d,validations:a}=U(t.type,t.validations);return t.type=d,t.validations=a,[n.key,t]}))}}function U(e,i){if(!i)return{type:e,validations:void 0};if(i.metaobject_definition_type&&typeof i.metaobject_definition_type=="string"){let n=u(i.metaobject_definition_type);return{type:`${e}<$app:${n}>`,validations:c({...i,metaobject_definition_type:void 0})}}if(i.metaobject_definition_types&&Array.isArray(i.metaobject_definition_types)&&i.metaobject_definition_types.every(n=>typeof n=="string")){let n=i.metaobject_definition_types.map(t=>u(t));return{type:`${e}<${n.map(t=>`$app:${t}`).join(",")}>`,validations:c({...i,metaobject_definition_types:void 0})}}return{type:e,validations:i}}function G(e){let i=n=>{try{return JSON.parse(n)}catch{return n}};return c(Object.fromEntries(e.filter(n=>n.value!==void 0&&n.name!=="metaobject_definition_id"&&n.name!=="metaobject_definition_ids").map(n=>[n.name,n.value?i(n.value):void 0])))}function re(e,i,n,t){let d=[[[i,"metafields",n,t,"name"],e.name],[[i,"metafields",n,t,"type"],e.type],[[i,"metafields",n,t,"description"],e.description]],a=[[[i,"metafields",n,t,"access","admin"],e.access?.admin],[[i,"metafields",n,t,"access","storefront"],e.access?.storefront],[[i,"metafields",n,t,"access","customer_account"],e.access?.customer_account],[[i,"metafields",n,t,"capabilities","admin_filterable"],e.capabilities?.admin_filterable||void 0]];return e.validations&&B(e.validations).forEach(({validationKey:l,actualValue:r})=>{d.push([[i,"metafields",n,t,"validations",l],r])}),[v(d),v(a)]}function me(e,i){let n=[[["metaobjects","app",i,"name"],e.name===i?void 0:e.name],[["metaobjects","app",i,"description"],e.description],[["metaobjects","app",i,"display_name_field"],e.display_name_field]],t=[[["metaobjects","app",i,"access","admin"],e.access?.admin],[["metaobjects","app",i,"access","storefront"],e.access?.storefront]];return e.capabilities?.translatable&&t.push([["metaobjects","app",i,"capabilities","translatable"],!0]),e.capabilities?.publishable&&t.push([["metaobjects","app",i,"capabilities","publishable"],!0]),e.capabilities?.renderable&&(t.push([["metaobjects","app",i,"capabilities","renderable"],!0]),e.capabilities?.renderable_meta_title_field&&t.push([["metaobjects","app",i,"capabilities","renderable_meta_title_field"],e.capabilities.renderable_meta_title_field]),e.capabilities?.renderable_meta_description_field&&t.push([["metaobjects","app",i,"capabilities","renderable_meta_description_field"],e.capabilities.renderable_meta_description_field])),Object.entries(e.fields).forEach(([d,a])=>{if(typeof a=="string")n.push([["metaobjects","app",i,"fields",d],a]);else{let o=Object.fromEntries(Object.entries(a).filter(([l,r])=>r!==void 0));Object.keys(o).length===1?n.push([["metaobjects","app",i,"fields",d],a.type]):(n.push([["metaobjects","app",i,"fields",d,"type"],a.type]),n.push([["metaobjects","app",i,"fields",d,"description"],a.description]),n.push([["metaobjects","app",i,"fields",d,"name"],a.name]),n.push([["metaobjects","app",i,"fields",d,"required"],a.required||void 0]),a.validations&&B(a.validations).forEach(({validationKey:r,actualValue:N})=>{n.push([["metaobjects","app",i,"fields",d,"validations",r],N])}))}}),[v(n),v(t)]}function B(e){return Object.entries(e).map(([i,n])=>{let t;return typeof n=="string"||typeof n=="number"||typeof n=="boolean"||Array.isArray(n)&&n.every(d=>typeof d=="string")?t=n:t=JSON.stringify(n),{validationKey:i,actualValue:t}})}function ce(e){let i=e.split(`
4
4
  `);for(let n of i)n.match(/^\s*\[/)?f(m`${p.green(n)}`):n.match(/^\s*#/)?f(m`${p.gray(n)}`):f(m`${n}`)}function H(e){switch(e){case"MERCHANT_READ_WRITE":return"merchant_read_write";case"MERCHANT_READ":case"PRIVATE":case"PUBLIC_READ":case"PUBLIC_READ_WRITE":case null:case void 0:return}}function Y(e){switch(e){case"PUBLIC_READ":return"public_read";case"NONE":case null:case void 0:return}}function ue(e){switch(e){case"READ":return"read";case"READ_WRITE":return"read_write";case"NONE":case null:case void 0:return}}function c(e){if(e&&!h(e)&&!(typeof e=="object"&&Object.values(e).every(i=>i===void 0)))return e}function v(e){return e.filter(([i,n])=>n!==void 0)}var b=F(W(),1);var S=class e extends E{static summary="Import metafield and metaobject definitions.";static descriptionWithMarkdown="Import metafield and metaobject definitions from your development store. [Read more about declarative custom data definitions](https://shopify.dev/docs/apps/build/custom-data/declarative-custom-data-definitions).";static description=this.descriptionForHelp();static flags={...R,...I,store:b.Flags.string({char:"s",description:"Store URL. Must be an existing development or Shopify Plus sandbox store.",env:"SHOPIFY_FLAG_STORE",parse:async i=>y(i)}),"include-existing":b.Flags.boolean({description:"Include existing declared definitions in the output.",default:!1,env:"SHOPIFY_FLAG_INCLUDE_EXISTING"})};async run(){let{appContextResult:i,...n}=await k({title:m`Loading application`,task:async()=>{let{flags:t}=await this.parse(e);await C(t.path);let d=await j({directory:t.path,clientId:t["client-id"],forceRelink:t.reset,userProvidedConfigName:t.config}),a=await M({appContextResult:d,storeFqdn:t.store,forceReselectStore:t.reset});return{appContextResult:d,appConfiguration:d.app.configuration,remoteApp:d.remoteApp,store:a,includeExistingDeclaredDefinitions:t["include-existing"]}}});return await q(n),{app:i.app}}};export{S as a};
@@ -1,4 +1,4 @@
1
- import{a as y0,b as F0}from"./chunk-I4FS7HYY.js";import{b as _0,o as T8}from"./chunk-YLQ3LNNY.js";import{a as O8}from"./chunk-VJEKDBGZ.js";import{$ as Jo,B as Mn,C as v0,D as mi,E as C0,F as Td,G as w0,H as Ke,I as zo,J as Vo,K as b0,L as io,M as Go,N as Ko,O as pn,P as qc,Q as gr,R as Ie,S as gi,T as dn,U as Fs,V as A0,W as Wc,Y as S0,Z as x0,_ as Hc,aa as P0,ba as O0,ca as T0,da as I0,e as d0,ga as B0,ha as R0,ia as N0,ja as M0,la as j0,m as h0,ma as Id,n as D0,na as $0,o as m0,p as xd,q as jr,qa as L0,r as Ho,ra as zc,v as Uc,w as kc,x as E0,y as Pd,z as Od}from"./chunk-WBTR5JZ6.js";import{a as g0}from"./chunk-4AXLWDKW.js";import{aa as P8}from"./chunk-HKNFZUAM.js";import{a as p0}from"./chunk-ZQKZC2KN.js";import{c as ys,d as wt}from"./chunk-LOKVWZD2.js";import{a as Gy,b as Ky}from"./chunk-OKX6PKAW.js";import{a as f0}from"./chunk-7IS6Q756.js";import{a as mr}from"./chunk-7AD5YCLL.js";import{$ as ms,D as Ly,E as Uy,G as Cd,J as ky,P as w8,Q as qy,R as b8,S as A8,T as Wy,U as S8,V as fn,W as Bc,Y as Hy,Z as Ct,aa as zy,b as v8,e as hi,ea as Vy,j as By,l as Ry,o as Ny,u as My}from"./chunk-VWYZCCRE.js";import{m as Rc,n as Yy,s as Xy,t as Zy,w as Nc,x as Mc}from"./chunk-NTFIW3VK.js";import{d as C8,e as jy,q as $y}from"./chunk-QF6EH4HX.js";import{a as _d}from"./chunk-32B4LIKH.js";import{a as Bn,b as ro}from"./chunk-GHO2S3W3.js";import{A as jc,B as e0,D as t0,E as Nr,F as bd,H as r0,J as _s,K as n0,M as i0,S as Di,V as $c,y as no,z as gs}from"./chunk-KCHERKZO.js";import{a as x8}from"./chunk-5HBIIYSK.js";import{b as Ds,d as Tc,e as Ic}from"./chunk-YTJ3EPD3.js";import{f as wd}from"./chunk-WR2MMFJO.js";import{i as k,k as Rn,l as Mr}from"./chunk-XUJURYN5.js";import{$ as vt,$a as Iy,A as Fd,Aa as Rr,Cb as Ae,Db as Lc,Eb as Se,Fa as Sy,Ia as di,Ja as xy,Ka as Sc,Kb as s0,Mb as a0,Nb as ce,Oa as Py,Ob as Nn,P as pi,Pa as Oy,Qb as c0,R as Bt,Rb as l0,Sa as xc,Ta as Ty,U as F8,V as E8,X as Cy,Xa as Y,Ya as Ut,Z as ps,_a as Ve,aa as Ed,b as E,ca as vd,db as ln,ea as bc,f as d8,fb as Pc,g as h8,ha as wy,hb as Oc,ia as Wo,j as D8,la as by,m as m8,o as g8,oa as ds,q as Fy,qa as $e,r as Ey,ra as to,sa as hs,ta as Br,tb as Jy,u as _8,ua as Ac,y as vy,ya as mt,z as y8,za as Ay}from"./chunk-COFGQT76.js";import{b as f8,c as p8,e as _y,f as yy,i as Qy}from"./chunk-B4OMIONW.js";import{g as o0,l as Ad,m as Sd,n as u0}from"./chunk-C4QR7Z4N.js";import{a as fs}from"./chunk-JD5P5RAJ.js";import{d as B,e as eo,f as ot,g as Te,h as hy,i as De,j as Pe,k as Cc,l as Dy,n as wc,o as my,s as gy,t as yd}from"./chunk-3VYOLEQE.js";import{a as ze,c as N,e as fi,f as l8,g as d}from"./chunk-VKWPEFWQ.js";var cF=N((Gc,aF)=>{d();(function(e,t){typeof Gc=="object"&&typeof aF<"u"?t(Gc,(E8(),l8(F8)),v8()):typeof define=="function"&&define.amd?define(["exports","tslib","graphql"],t):(e=typeof globalThis<"u"?globalThis:e||self,t(e["graphql-tag"]={},e.tslib,e.graphql))})(Gc,(function(e,t,r){"use strict";var n=new Map,o=new Map,s=!0,a=!1;function l(q){return q.replace(/[\s,]+/g," ").trim()}function p(q){return l(q.source.body.substring(q.start,q.end))}function D(q){var J=new Set,Q=[];return q.definitions.forEach(function(fe){if(fe.kind==="FragmentDefinition"){var ye=fe.name.value,We=p(fe.loc),gt=o.get(ye);gt&&!gt.has(We)?s&&console.warn("Warning: fragment with name "+ye+` already exists.
1
+ import{a as y0,b as F0}from"./chunk-7IRPE3M5.js";import{b as _0,o as T8}from"./chunk-YLQ3LNNY.js";import{a as O8}from"./chunk-VJEKDBGZ.js";import{$ as Jo,B as Mn,C as v0,D as mi,E as C0,F as Td,G as w0,H as Ke,I as zo,J as Vo,K as b0,L as io,M as Go,N as Ko,O as pn,P as qc,Q as gr,R as Ie,S as gi,T as dn,U as Fs,V as A0,W as Wc,Y as S0,Z as x0,_ as Hc,aa as P0,ba as O0,ca as T0,da as I0,e as d0,ga as B0,ha as R0,ia as N0,ja as M0,la as j0,m as h0,ma as Id,n as D0,na as $0,o as m0,p as xd,q as jr,qa as L0,r as Ho,ra as zc,v as Uc,w as kc,x as E0,y as Pd,z as Od}from"./chunk-PQCALXSD.js";import{a as g0}from"./chunk-46U6C6C6.js";import{da as P8}from"./chunk-P2MVR6CG.js";import{a as p0}from"./chunk-DH5E6NM3.js";import{c as ys,d as wt}from"./chunk-OERMQ2FP.js";import{a as Gy,b as Ky}from"./chunk-LWF4EV22.js";import{a as f0}from"./chunk-KY36HSIB.js";import{a as mr}from"./chunk-525BMYNR.js";import{$ as ms,D as Ly,E as Uy,G as Cd,J as ky,P as w8,Q as qy,R as b8,S as A8,T as Wy,U as S8,V as fn,W as Bc,Y as Hy,Z as Ct,aa as zy,b as v8,e as hi,ea as Vy,j as By,l as Ry,o as Ny,u as My}from"./chunk-3E3MCY5O.js";import{m as Rc,n as Yy,s as Xy,t as Zy,w as Nc,x as Mc}from"./chunk-FQKURDZR.js";import{d as C8,e as jy,q as $y}from"./chunk-Q555FV2X.js";import{a as _d}from"./chunk-TQ7MHGY4.js";import{a as Bn,b as ro}from"./chunk-LIQSNIB3.js";import{A as jc,B as e0,D as t0,E as Nr,F as bd,H as r0,J as _s,K as n0,M as i0,S as Di,V as $c,y as no,z as gs}from"./chunk-RCYQPOJW.js";import{a as x8}from"./chunk-5HBIIYSK.js";import{b as Ds,d as Tc,e as Ic}from"./chunk-YTJ3EPD3.js";import{f as wd}from"./chunk-PQH4U2XV.js";import{i as k,k as Rn,l as Mr}from"./chunk-ZZ7SOJHH.js";import{$ as vt,$a as Iy,A as Fd,Aa as Rr,Cb as Ae,Db as Lc,Eb as Se,Fa as Sy,Ia as di,Ja as xy,Ka as Sc,Kb as s0,Mb as a0,Nb as ce,Oa as Py,Ob as Nn,P as pi,Pa as Oy,Qb as c0,R as Bt,Rb as l0,Sa as xc,Ta as Ty,U as F8,V as E8,X as Cy,Xa as Y,Ya as Ut,Z as ps,_a as Ve,aa as Ed,b as E,ca as vd,db as ln,ea as bc,f as d8,fb as Pc,g as h8,ha as wy,hb as Oc,ia as Wo,j as D8,la as by,m as m8,o as g8,oa as ds,q as Fy,qa as $e,r as Ey,ra as to,sa as hs,ta as Br,tb as Jy,u as _8,ua as Ac,y as vy,ya as mt,z as y8,za as Ay}from"./chunk-3F42A3XV.js";import{b as f8,c as p8,e as _y,f as yy,i as Qy}from"./chunk-B4OMIONW.js";import{g as o0,l as Ad,m as Sd,n as u0}from"./chunk-2R2PKQQV.js";import{a as fs}from"./chunk-JD5P5RAJ.js";import{d as B,e as eo,f as ot,g as Te,h as hy,i as De,j as Pe,k as Cc,l as Dy,n as wc,o as my,s as gy,t as yd}from"./chunk-3VYOLEQE.js";import{a as ze,c as N,e as fi,f as l8,g as d}from"./chunk-VKWPEFWQ.js";var cF=N((Gc,aF)=>{d();(function(e,t){typeof Gc=="object"&&typeof aF<"u"?t(Gc,(E8(),l8(F8)),v8()):typeof define=="function"&&define.amd?define(["exports","tslib","graphql"],t):(e=typeof globalThis<"u"?globalThis:e||self,t(e["graphql-tag"]={},e.tslib,e.graphql))})(Gc,(function(e,t,r){"use strict";var n=new Map,o=new Map,s=!0,a=!1;function l(q){return q.replace(/[\s,]+/g," ").trim()}function p(q){return l(q.source.body.substring(q.start,q.end))}function D(q){var J=new Set,Q=[];return q.definitions.forEach(function(fe){if(fe.kind==="FragmentDefinition"){var ye=fe.name.value,We=p(fe.loc),gt=o.get(ye);gt&&!gt.has(We)?s&&console.warn("Warning: fragment with name "+ye+` already exists.
2
2
  graphql-tag enforces all fragment names across your application to be unique; read more about
3
3
  this in the docs: http://dev.apollodata.com/core/fragments.html#unique-names`):gt||o.set(ye,gt=new Set),gt.add(We),J.has(We)||(J.add(We),Q.push(fe))}else Q.push(fe)}),t.__assign(t.__assign({},q),{definitions:Q})}function g(q){var J=new Set(q.definitions);J.forEach(function(fe){fe.loc&&delete fe.loc,Object.keys(fe).forEach(function(ye){var We=fe[ye];We&&typeof We=="object"&&J.add(We)})});var Q=q.loc;return Q&&(delete Q.startToken,delete Q.endToken),q}function F(q){var J=l(q);if(!n.has(J)){var Q=r.parse(q,{experimentalFragmentVariables:a,allowLegacyFragmentVariables:a,experimentalFragmentArguments:a});if(!Q||Q.kind!=="Document")throw new Error("Not a valid GraphQL document.");n.set(J,g(D(Q)))}return n.get(J)}function w(q){for(var J=[],Q=1;Q<arguments.length;Q++)J[Q-1]=arguments[Q];typeof q=="string"&&(q=[q]);var fe=q[0];return J.forEach(function(ye,We){ye&&ye.kind==="Document"?fe+=ye.loc.source.body:fe+=ye,fe+=q[We+1]}),F(fe)}function v(){n.clear(),o.clear()}function S(){s=!1}function O(){a=!0}function P(){a=!1}var I={gql:w,resetCaches:v,disableFragmentWarnings:S,enableExperimentalFragmentVariables:O,disableExperimentalFragmentVariables:P};(function(q){q.gql=I.gql,q.resetCaches=I.resetCaches,q.disableFragmentWarnings=I.disableFragmentWarnings,q.enableExperimentalFragmentVariables=I.enableExperimentalFragmentVariables,q.disableExperimentalFragmentVariables=I.disableExperimentalFragmentVariables})(w||(w={})),w.default=w;var U=w;e.default=U,e.disableExperimentalFragmentVariables=P,e.disableFragmentWarnings=S,e.enableExperimentalFragmentVariables=O,e.gql=w,e.resetCaches=v,Object.defineProperty(e,"__esModule",{value:!0})}))});var fF=N((YH,lF)=>{d();lF.exports=cF().gql});var yF=N(_F=>{d();var X8=Object.create,Kc=Object.defineProperty,Z8=Object.getPrototypeOf,Q8=Object.prototype.hasOwnProperty,eB=Object.getOwnPropertyNames,tB=Object.getOwnPropertyDescriptor,dF=e=>Kc(e,"__esModule",{value:!0}),rB=(e,t)=>{dF(e);for(var r in t)Kc(e,r,{get:t[r],enumerable:!0})},nB=(e,t,r)=>{if(dF(e),t&&typeof t=="object"||typeof t=="function")for(let n of eB(t))!Q8.call(e,n)&&n!=="default"&&Kc(e,n,{get:()=>t[n],enumerable:!(r=tB(t,n))||r.enumerable});return e},Jc=e=>e&&e.__esModule?e:nB(Kc(e!=null?X8(Z8(e)):{},"default",{value:e,enumerable:!0}),e);rB(_F,{default:()=>pB,generateContentsFromGraphqlString:()=>gF,generateGraphQLString:()=>DF});var iB=Jc(ze("fs")),oB=Jc(fF()),uB=Jc(ze("readline")),pF=Jc(ze("path")),hF=(e,t)=>{let r=t?t(e):e;return JSON.stringify(r,(n,o)=>o===void 0?"__undefined":o).replace(/"__undefined"/g,"undefined")},sB=(e,t)=>{let r=new Set,n=[],o=s=>{r.has(s)||(r.add(s),s.imports.forEach(a=>{let l=t[a.absolutePath];o(l)}),n.unshift(s))};return e.forEach(o),n},aB=e=>new Promise(t=>{let r=uB.default.createInterface({input:iB.default.createReadStream(e)}),n="",o=[],s=!1,a=(l,p)=>{let D=p.replace(l,""),g=D.replace(/"|'/g,""),F=pF.default.join(pF.default.dirname(e),g);o.push({absolutePath:F,relativePath:D})};r.on("line",l=>{l.startsWith("#import ")?a("#import ",l):l.startsWith("# import ")?a("# import ",l):s?n+=l+`
4
4
  `:l[0]!=="#"&&l!==""&&(s=!0,n+=l+`
@@ -247,7 +247,7 @@ Use caution as this may include production data on live stores.`]}:{}}):l=await
247
247
  `,r=`
248
248
  # Learn more at https://shopify.dev/docs/apps/tools/cli/configuration#access_scopes`,n=e.split(/(\r\n|\r|\n)/);return n.unshift(`
249
249
  `),n.unshift(t),n.forEach((o,s)=>{o==="[access_scopes]"&&n.splice(s+1,0,r)}),n.join("")}function wR(e){let t=e.webhooks;if(Array.isArray(t?.subscriptions)&&t.subscriptions.length){let r=io(e?.application_url);t.subscriptions=x0(t.subscriptions),t.subscriptions=t.subscriptions.map(({uri:n,...o})=>({uri:r&&n.includes(r)?n.replace(r,""):n,...o}))}return e}d();d();d();var bR=Vo.extend({app_proxy:E.object({url:E.preprocess(io,kc(E.string({invalid_type_error:"Value must be string"}))),subpath:E.string({invalid_type_error:"Value must be a string"}),prefix:E.string({invalid_type_error:"Value must be a string"})}).optional()}),Eh="app_proxy",AR={forward:(e,t)=>{let r=e;if(!r.app_proxy)return{};let n;return"application_url"in t&&(n=t?.application_url),{url:Go(r.app_proxy.url,n),subpath:r.app_proxy.subpath,prefix:r.app_proxy.prefix}},reverse:e=>{let t=e;return{app_proxy:{url:io(t.url),subpath:t.subpath,prefix:t.prefix}}}},SR=gi({identifier:Eh,schema:bR,transformConfig:AR,getDevSessionUpdateMessages:async e=>e.app_proxy?[`Using URL: ${e.app_proxy.url}`,"Any changes to prefix and subpath will only apply to new installs"]:[],patchWithAppDevURLs:(e,t)=>{t.appProxy&&(e.app_proxy={url:t.appProxy.proxyUrl,subpath:t.appProxy.proxySubPath,prefix:t.appProxy.proxySubPathPrefix})}}),fv=SR;d();var xR=Vo.extend({pos:E.object({embedded:E.boolean({invalid_type_error:"Value must be Boolean"})}).optional()}),vh="point_of_sale",PR={embedded:"pos.embedded"},OR=gi({identifier:vh,schema:xR,transformConfig:PR}),pv=OR;d();d();function dv(e,t){let r=e;if(!r.events?.subscription)return e;let n;t&&"application_url"in t&&(n=t?.application_url);let{handle:o,...s}=r,a=r.events.subscription,l=!Array.isArray(a),p=IR(a).map(D=>{let{handle:g,...F}=D,w=l?F:D;return typeof w.uri=="string"?{...w,uri:Go(w.uri,n)}:w});return{...s,events:{...r.events,subscription:Array.isArray(a)?p:p[0]}}}function hv(e,t){let{api_version:r,subscription:n}=Ct(e,"events")??{},o=l=>{let{identifier:p,api_version:D,...g}=l;return D!==void 0&&D!==r?{...g,api_version:D}:g},s;if(Array.isArray(n))s=n.map(o);else if(n){let l=t?.handle??n.handle??TR(n);s=[o({...n,handle:l})]}let a={};return r!==void 0&&(a.api_version=r),s!==void 0&&(a.subscription=s),{events:a}}function TR(e){return vt([e.topic,...e.actions].join("-")).slice(0,Mn).replace(/-$/,"")}function IR(e){return Array.isArray(e)?e:[e]}var gl="events",BR={forward:dv,reverse:hv},Dv=E.string().trim().nonempty("Handle can't be empty").max(Mn,`Handle can't exceed ${Mn} characters`).regex(/^[a-zA-Z0-9_-]*$/,"Handle can only contain alphanumeric characters, underscores and hyphens").refine(e=>e!==gl,'The handle "events" is reserved for the legacy events module. Choose a different subscription handle.'),RR=E.object({subscription:E.unknown().optional()}).passthrough(),NR=Vo.extend({handle:Dv.optional(),events:RR.optional()}).superRefine((e,t)=>{let r=e.events?.subscription;if(r===void 0||Array.isArray(r))return;let n=Dv.safeParse(e.handle);n.success||n.error.issues.forEach(o=>t.addIssue({...o,path:["handle"]}))}),MR=E.preprocess(e=>{if(typeof e!="object"||e===null||Array.isArray(e)||!("handle"in e))return e;let t=Ct(e,"events.subscription");if(t!==void 0&&!Array.isArray(t))return e;let{handle:r,...n}=e;return n},NR),jR=gi({identifier:gl,schema:MR,transformConfig:BR,expandConfig:e=>{let t=e.events?.subscription;return Array.isArray(t)?t.map(r=>{let{handle:n,...o}=r;return{handle:n,events:{...e.events,subscription:o}}}):[e]},getIdentity:e=>{if(e.handle)return{handle:e.handle,uid:e.handle}},getTarget:e=>{let t=e.events?.subscription?.topic;return typeof t=="string"?t:void 0}}),mv=jR;d();var $R={forward:UR,reverse:e=>kR(e)},wh="privacy_compliance_webhooks",LR=gi({identifier:wh,schema:Hc,transformConfig:$R}),gv=LR;function UR(e,t){let r=Ct(e,"webhooks"),n;"application_url"in t&&(n=t?.application_url);let o=zy({customers_redact_url:Ch(qR(r),n),customers_data_request_url:Ch(WR(r),n),shop_redact_url:Ch(HR(r),n)});if(Object.keys(o).length===0)return o;{let{api_version:s}=r;return{api_version:s,...o}}}function kR(e){let t=Ct(e,"customers_redact_url"),r=Ct(e,"customers_data_request_url"),n=Ct(e,"shop_redact_url"),o=[];return r&&o.push({compliance_topics:[Wc.CustomersDataRequest],uri:r}),t&&o.push({compliance_topics:[Wc.CustomersRedact],uri:t}),n&&o.push({compliance_topics:[Wc.ShopRedact],uri:n}),o.length===0?{}:{webhooks:{subscriptions:S0(o),privacy_compliance:void 0}}}function bh(e,t){return e.subscriptions?.find(r=>r.compliance_topics?.includes(t))?.uri}function Ch(e,t){return t&&e?.startsWith("/")?`${io(t)}${e}`:e}function qR(e){return bh(e,"customers/redact")??e?.privacy_compliance?.customer_deletion_url}function WR(e){return bh(e,"customers/data_request")??e?.privacy_compliance?.customer_data_request_url}function HR(e){return bh(e,"shop/redact")??e?.privacy_compliance?.shop_deletion_url}d();var zR="@shopify/post-purchase-ui-extensions",VR=Ke.extend({metafields:E.array(mi).optional()}),GR=Ie({identifier:"checkout_post_purchase",dependency:zR,partnersWebIdentifier:"post_purchase",schema:VR,appModuleFeatures:e=>["ui_preview","cart_url","esbuild","single_js_entry_path"],getOutputRelativePath:e=>`dist/${e.handle}.js`,clientSteps:[{lifecycle:"deploy",steps:[{id:"bundle-ui",name:"Bundle UI Extension",type:"bundle_ui",config:{}}]}],deployConfig:async(e,t)=>({metafields:e.metafields??[]})}),_v=GR;d();var KR="@shopify/checkout-ui-extensions",JR=Ke.extend({name:E.string(),extension_points:E.array(E.string()).optional(),metafields:E.array(mi).optional(),settings:E.object({fields:E.any().optional()}).optional()}),YR=Ie({identifier:"checkout_ui_extension",dependency:KR,schema:JR,appModuleFeatures:e=>["ui_preview","cart_url","esbuild","single_js_entry_path","generates_source_maps"],getOutputRelativePath:e=>`dist/${e.handle}.js`,clientSteps:[{lifecycle:"deploy",steps:[{id:"bundle-ui",name:"Bundle UI Extension",type:"bundle_ui",config:{}}]}],deployConfig:async(e,t)=>({extension_points:e.extension_points,capabilities:e.capabilities,supported_features:e.supported_features,metafields:e.metafields??[],name:e.name,settings:e.settings,localization:await pn(t,"checkout_ui")})}),yv=YR;d();d();d();var bt={customer_reference:"customer_reference",order_reference:"order_reference",product_reference:"product_reference",marketing_activity_reference:"marketing_activity_reference",abandonment_reference:"abandonment_reference",company_reference:"company_reference",company_contact_reference:"company_contact_reference"},TQ=["customer","order","product","marketing_activity","abandonment","company","company_contact"],Fv=[bt.customer_reference,bt.order_reference,bt.product_reference,bt.company_reference,bt.company_contact_reference],Ev=[bt.customer_reference,bt.order_reference,bt.product_reference,bt.marketing_activity_reference,bt.abandonment_reference,bt.company_reference,bt.company_contact_reference],Qe={boolean:"boolean",email:"email",multiLineText:"multi_line_text_field",int:"number_integer",singleLineText:"single_line_text_field",url:"url",decimal:"number_decimal",schemaTypeReference:"schema_type_reference"},vv=[[Qe.boolean,"checkbox"],[Qe.email,"email"],[Qe.multiLineText,"text-multi-line"],[Qe.int,"int"],[Qe.singleLineText,"text-single-line"],[Qe.url,"url"],[Qe.decimal,"number"],[Qe.schemaTypeReference,"schema-type-reference"]],XR=[Qe.boolean,Qe.email,Qe.multiLineText,Qe.int,Qe.singleLineText,Qe.url,Qe.decimal],ZR=[Qe.boolean,Qe.email,Qe.singleLineText,Qe.url,Qe.decimal,Qe.schemaTypeReference],Cv=vv.filter(([e])=>XR.includes(e)),wv=vv.filter(([e])=>ZR.includes(e));d();d();var _l=async(e,t)=>{if(!t)return"";let r=await Ve(B(e,t));if(r.length>1)throw new Error("Multiple files found for schema path");if(r.length===0)throw new Error("No file found for schema path");return $e(r[0])};d();var QR=new Map(Cv),eN=new Map(wv),tN=(e,t)=>{let r=t==="flow_action"?QR:eN,n=Ah(e.type),o=n?r.get("schema_type_reference"):r.get(e.type);if(typeof e.key!="string")throw new k(`key property must be specified for non-commerce object fields in ${JSON.stringify(e)}`);if(!o)throw new k(`Field type ${e.type} is not supported on Flow ${t==="flow_action"?"Actions":"Triggers"}`);let s={name:e.key,description:e.description,uiType:o};return t==="flow_action"&&(s.label=e.name,s.required=e.required),n&&(s.typeRefName=e.type.replace("schema.","")),s},rN=(e,t)=>{if(t==="flow_trigger"&&!Fv.includes(e.type))throw new k(`Commerce object ${e.type} is not supported for Flow Triggers`);if(t==="flow_action"&&!Ev.includes(e.type))throw new k(`Commerce object ${e.type} is not supported for Flow Actions`);let r=e.type.replace("_reference",""),n={name:`${r}_id`,uiType:t==="flow_action"?"commerce-object-id":r,description:e.description};return r==="marketing_activity"&&(n.uiType="marketing-activity-id",n.marketingActivityCreateUrl=e.marketingActivityCreateUrl,n.marketingActivityDeleteUrl=e.marketingActivityDeleteUrl),t==="flow_action"&&(n.label=`${Wo(r)} ID`,n.required=e.required),n},yl=(e,t)=>t?t.map(n=>Object.keys(bt).includes(n.type)?rN(n,e):tN(n,e)):[];var Sh=w0.extend({key:E.string().regex(/^[a-zA-Z\s]*$/,{message:"String must contain only alphabetic characters and spaces"}).optional()}),nN=zo.extend({type:E.literal("flow_trigger"),name:E.string(),schema:E.string().optional(),settings:E.object({fields:E.array(Sh).optional()}).optional()}).refine(e=>{let t=e.settings?.fields??[],r=t.every((o,s)=>Fl(o,"flow_trigger",e.handle,s)),n=Av(t,e.schema);return r&&n}),iN=Ie({identifier:"flow_trigger",schema:nN,appModuleFeatures:e=>[],deployConfig:async(e,t)=>({title:e.name,description:e.description,fields:yl("flow_trigger",e.settings?.fields),schema_patch:await _l(t,e.schema)})}),bv=iN;function Sv(e,t,r,n){let o=`'${e}' property must be a string for 'field[${n}]' ${JSON.stringify(t)} of flow extension '${r}'`;return{required_error:o,invalid_type_error:o}}var xh=E.object({type:E.string(),description:E.string().optional()}).strict(),Fl=(e,t,r,n)=>{let o=Object.keys(bt).includes(e.type);return o?o?xh.extend({required:E.boolean().optional(),marketingActivityCreateUrl:E.string().optional(),marketingActivityDeleteUrl:E.string().optional()}).parse(e):xh.parse(e):t==="flow_action"?xh.extend({key:E.string(Sv("key",e,r,n)),name:E.string(Sv("name",e,r,n)),required:E.boolean().optional()}).parse(e):Sh.parse(e)},Ah=e=>e.startsWith("schema."),Ns=e=>kc(e,{message:'Invalid URL: URL must be an absolute HTTPS URL or a relative URL starting with a single slash (e.g. "/api/endpoint").'}).refine(t=>!E0.test(t),{message:"Invalid URL: URL must not contain control characters such as newlines or tabs."}).refine(t=>!t.startsWith("//"),{message:"Invalid URL: Relative URLs must start with a single slash."}),xv=(e,t,r)=>{if(e||t){if(!e)throw new E.ZodError([{code:E.ZodIssueCode.custom,path:["extensions[0].config_page_url"],message:"To set a custom configuration page a `config_page_url` must be specified."}]);if(!t)throw new E.ZodError([{code:E.ZodIssueCode.custom,path:["extensions[0].config_page_preview_url"],message:"To set a custom configuration page a `config_page_preview_url` must be specified."}]);if(!r)throw new E.ZodError([{code:E.ZodIssueCode.custom,path:["extensions[0].validation_url"],message:"To set a custom configuration page a `validation_url` must be specified."}])}return!0},Av=(e,t)=>{if(e.some(r=>Ah(r.type))&&!t)throw new E.ZodError([{code:E.ZodIssueCode.custom,path:["extensions[0].schema"],message:"To reference schema types a `schema` must be specified."}]);return!0},Pv=(e,t)=>{if(e||t){if(!e)throw new E.ZodError([{code:E.ZodIssueCode.custom,path:["extensions[0].return_type_ref"],message:"When uploading a schema a `return_type_ref` must be specified."}]);if(!t)throw new E.ZodError([{code:E.ZodIssueCode.custom,path:["extensions[0].schema"],message:"To set a return type a `schema` must be specified."}])}return!0};d();var Ov=["runtime_url","validation_url","config_page_url","config_page_preview_url"];var Ms="Flow action",oN=zo.extend({type:E.literal("flow_action"),name:E.string(),runtime_url:Ns(E.string({invalid_type_error:"Value must be string"})),validation_url:Ns(E.string({invalid_type_error:"Value must be string"})).optional(),config_page_url:Ns(E.string({invalid_type_error:"Value must be string"})).optional(),config_page_preview_url:Ns(E.string({invalid_type_error:"Value must be string"})).optional(),schema:E.string().optional(),return_type_ref:E.string().optional()}).refine(e=>{let t=xv(e.config_page_url,e.config_page_preview_url,e.validation_url),n=(e.settings?.fields??[]).every((s,a)=>Fl(s,"flow_action",e.handle,a)),o=Pv(e.return_type_ref,e.schema);return t&&n&&o}),uN=Ie({identifier:"flow_action",schema:oN,appModuleFeatures:e=>[],patchWithAppDevURLs:(e,t)=>{for(let r of Ov){let n=e[r];typeof n=="string"&&n.startsWith("/")&&(e[r]=Ko(Ms,r,n,t.applicationUrl))}},deployConfig:async(e,t,r,n,o)=>{let s=o?.appConfiguration,a=typeof s?.application_url=="string"?s.application_url:void 0;return{title:e.name,description:e.description,url:Ko(Ms,"runtime_url",e.runtime_url,a),fields:yl("flow_action",e.settings?.fields),validation_url:e.validation_url?Ko(Ms,"validation_url",e.validation_url,a):void 0,custom_configuration_page_url:e.config_page_url?Ko(Ms,"config_page_url",e.config_page_url,a):void 0,custom_configuration_page_preview_url:e.config_page_preview_url?Ko(Ms,"config_page_preview_url",e.config_page_preview_url,a):void 0,schema_patch:await _l(t,e.schema),return_type_ref:e.return_type_ref}}}),Tv=uN;d();import sN from"fs";var Iv=["buyer_experience","customers","fulfillment","inventory_and_merch","loyalty","orders","promotion","risk","b2b","payment_reminders","custom_data","error_monitoring"],aN=["capture_at_fulfillment"],cN=zo.extend({type:E.literal("flow_template"),name:E.string(),description:E.string().max(1024),template:E.object({categories:E.array(E.string().refine(e=>Iv.concat(aN).includes(e),e=>({message:`${e} is not a valid category. Valid categories include: ${Iv.join(", ")}.`}))),module:E.string(),require_app:E.boolean().optional(),discoverable:E.boolean().optional(),allow_one_click_activate:E.boolean().optional(),enabled:E.boolean().optional()})}),lN=Ie({identifier:"flow_template",schema:cN,appModuleFeatures:e=>["ui_preview"],clientSteps:[{lifecycle:"deploy",steps:[{id:"copy-files",name:"Copy Files",type:"include_assets",config:{inclusions:[{type:"pattern",include:["**/*.flow","**/*.json","**/*.toml"]}]}}]}],deployConfig:async(e,t)=>({template_handle:e.handle,name:e.name,description:e.description,categories:e.template.categories,require_app:e.template.require_app,discoverable:e.template.discoverable,allow_one_click_activate:e.template.allow_one_click_activate,enabled:e.template.enabled,definition:await fN(t,e.template.module),localization:await pn(t,e.name)})});async function fN(e,t){let n=(await Ve(B(e,t)))[0];if(!n)throw new k(`Missing flow file with the path ${B(e,t)}`);return sN.readFileSync(n,"base64")}var Bv=lN;d();var pN=dn({identifier:"flow_trigger_lifecycle_callback",uidStrategy:"uuid",experience:"extension",appModuleFeatures:()=>[],appRelativeUrlFields:["url"]}),Rv=pN;d();var dN="Input variables must be defined either at the extension level or on a target, not both. Remove `input.variables` from your extension configuration. Declare `input_variables` on each target that needs them instead.",Nv=E.object({namespace:E.string(),key:E.string()}),hN=Ke.extend({build:E.object({command:E.string().transform(e=>e.trim()===""?void 0:e).optional(),path:E.string().optional(),watch:E.union([E.string(),E.string().array()]).optional(),wasm_opt:E.boolean().optional().default(!0),typegen_command:E.string().transform(e=>e.trim()===""?void 0:e).optional()}).optional(),name:E.string(),type:E.string(),configuration_ui:E.boolean().optional().default(!0),ui:E.object({enable_create:E.boolean().optional(),paths:E.object({create:E.string(),details:E.string()}).optional(),handle:E.string().optional()}).optional(),api_version:E.string(),input:E.object({variables:Nv.optional()}).optional(),targeting:E.array(E.object({target:E.string(),input_query:E.string().optional(),input_variables:Nv.optional(),export:E.string().optional()})).optional()}).superRefine((e,t)=>{e.input?.variables&&e.targeting?.some(r=>r.input_variables)&&t.addIssue({code:E.ZodIssueCode.custom,path:["input","variables"],message:dN})}),DN=Ie({identifier:"function",additionalIdentifiers:["order_discounts","cart_checkout_validation","cart_transform","delivery_customization","payment_customization","product_discounts","shipping_discounts","fulfillment_constraints","order_routing_location_rule","local_pickup_delivery_option_generator","pickup_point_delivery_option_generator"],schema:hN,appModuleFeatures:e=>["function"],getOutputRelativePath:e=>B("dist","index.wasm"),devSessionWatchConfig:e=>{let t=e.configuration;if(!t.build||!t.build.watch)return;let r=[t.build.watch].flat().map(n=>B(e.directory,n));return r.push(B(e.directory,"locales","**.json")),r.push(B(e.directory,"**","!(.)*.graphql")),r.push(B(e.directory,"**.toml")),{paths:r}},clientSteps:[{lifecycle:"deploy",steps:[{id:"build-function",name:"Build Function",type:"build_function",config:{}}]}],deployConfig:async(e,t,r)=>{let n,o=Tc(),s=B(t,"input.graphql");await Y(s)&&(n=await $e(s));let a=e.targeting&&await Promise.all(e.targeting.map(async p=>{let D;return p.input_query&&(D=await mN(B(t,p.input_query))),{handle:p.target,export:p.export,input_query:D,input_query_variables:p.input_variables?{single_json_metafield:p.input_variables}:void 0}})),l;return e.ui?.paths&&(l={app_bridge:{details_path:e.ui.paths.details,create_path:e.ui.paths.create}}),e.ui?.handle!==void 0&&(l={...l,ui_extension_handle:e.ui.handle}),{title:e.name,module_id:o,description:e.description,app_key:r,api_type:e.type==="function"?void 0:e.type,api_version:e.api_version,input_query:n,input_query_variables:e.input?.variables?{single_json_metafield:e.input.variables}:void 0,ui:l,enable_creation_ui:e.ui?.enable_create??!0,localization:await pn(t,"function"),targets:a}},preDeployValidation:async e=>{if(!await Y(e.outputPath))throw new k(Se`The function extension "${e.handle}" hasn't compiled the wasm in the expected path: ${e.outputPath}`,"Make sure the build command outputs the wasm in the expected directory.")}});async function mN(e){if(await Y(e))return $e(e);throw new k(`No input query file at ${e}.`,"Create the file or remove the line referencing it in the extension's TOML.")}var Mv=DN;d();d();d();var jv=50,Fr=Ke.extend({api_version:E.string(),payment_session_url:E.string().url(),refund_session_url:E.string().url().optional(),capture_session_url:E.string().url().optional(),void_session_url:E.string().url().optional(),supported_countries:E.array(E.string()),supported_payment_methods:E.array(E.string()),test_mode_available:E.boolean(),merchant_label:E.string().max(jv),input:E.object({metafield_identifiers:E.object({namespace:E.string(),key:E.string()}).optional()}).optional()}),yi=E.object({buyer_label:E.string().max(jv).optional(),buyer_label_translations:E.array(E.object({locale:E.string(),label:E.string()})).optional()}),nu=E.object({supports_installments:E.boolean().optional(),supports_deferred_payments:E.boolean().optional()}),El=E.object({multiple_capture:E.boolean().optional()}),Fi=E.object({confirmation_callback_url:E.string().url().optional(),supports_3ds:E.boolean()}),Dn=E.object({supported_buyer_contexts:E.array(E.object({currency:E.string(),countries:E.array(E.string()).nonempty().optional()}).strict()).optional().refine(e=>e===void 0||e.every(t=>t.countries)||e.every(t=>!t.countries),{message:"Must all be defined with only a currency, or must all be defined with a currency plus countries -- a mixture of the two is not allowed"})});var Ph="payments.offsite.render",$v=Fr.merge(yi).merge(nu).merge(Fi).merge(El).merge(Dn).extend({targeting:E.array(E.object({target:E.literal(Ph)})).length(1),supports_oversell_protection:E.boolean().optional(),supports_3ds:E.boolean().optional()}).refine(e=>!e.supports_oversell_protection||e.confirmation_callback_url,{message:"Property required when supports_oversell_protection is true",path:["confirmation_callback_url"]}).refine(e=>e.supports_installments===e.supports_deferred_payments,{message:"supports_installments and supports_deferred_payments must be the same"});function Vee(e){return{api_version:e.api_version,payment_session_url:e.start_payment_session_url,refund_session_url:e.start_refund_session_url,capture_session_url:e.start_capture_session_url,void_session_url:e.start_void_session_url,confirmation_callback_url:e.confirmation_callback_url,multiple_capture:e.multiple_capture,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,buyer_label:e.default_buyer_label,buyer_label_translations:e.buyer_label_to_locale,supports_oversell_protection:e.supports_oversell_protection,supports_3ds:e.supports_3ds,supports_deferred_payments:e.supports_deferred_payments,supports_installments:e.supports_installments}}async function Lv(e){return{api_version:e.api_version,start_payment_session_url:e.payment_session_url,start_refund_session_url:e.refund_session_url,start_capture_session_url:e.capture_session_url,start_void_session_url:e.void_session_url,confirmation_callback_url:e.confirmation_callback_url,multiple_capture:e.multiple_capture,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,default_buyer_label:e.buyer_label,buyer_label_to_locale:e.buyer_label_translations,supports_oversell_protection:e.supports_oversell_protection,supports_3ds:e.supports_3ds,supports_deferred_payments:e.supports_deferred_payments,supports_installments:e.supports_installments}}d();d();function Ei(e,t){let r=e.ui_extension_handle;if(r||!("ui_extension_registration_uuid"in e))return r;let n=t.find(o=>o.uuid===e.ui_extension_registration_uuid)?.title;return n?vt(n):r}var Oh="payments.redeemable.render",Uv=Fr.merge(yi).merge(Dn).extend({targeting:E.array(E.object({target:E.literal(Oh)})).length(1),api_version:E.string(),balance_url:E.string().url(),ui_extension_handle:E.string().optional(),checkout_payment_method_fields:E.array(E.object({type:E.union([E.literal("string"),E.literal("number"),E.literal("boolean")]),required:E.boolean(),key:E.string()})).optional()});function tte(e,t){let r=Ei(e,t);return{api_version:e.api_version,payment_session_url:e.start_payment_session_url,refund_session_url:e.start_refund_session_url,capture_session_url:e.start_capture_session_url,void_session_url:e.start_void_session_url,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,buyer_label:e.default_buyer_label,buyer_label_translations:e.buyer_label_to_locale,balance_url:e.balance_url,checkout_payment_method_fields:e.checkout_payment_method_fields?.map(n=>({key:n.key,type:n.type,required:n.required})),ui_extension_handle:r}}async function kv(e){let t=e.supported_payment_methods[0]==="gift-card"?"gift_card":null;return{api_version:e.api_version,start_payment_session_url:e.payment_session_url,start_refund_session_url:e.refund_session_url,start_capture_session_url:e.capture_session_url,start_void_session_url:e.void_session_url,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,default_buyer_label:e.buyer_label,buyer_label_to_locale:e.buyer_label_translations,balance_url:e.balance_url,redeemable_type:t,checkout_payment_method_fields:e.checkout_payment_method_fields,ui_extension_handle:e.ui_extension_handle}}d();var Th="payments.custom-onsite.render",qv=7,Wv=Fr.merge(yi).merge(nu).merge(Fi).merge(Dn).extend({targeting:E.array(E.object({target:E.literal(Th)})).length(1),supports_3ds:E.boolean().optional(),update_payment_session_url:E.string().url().optional(),multiple_capture:E.boolean().optional(),supports_oversell_protection:E.boolean().optional(),modal_payment_method_fields:E.array(E.object({})).optional(),ui_extension_handle:E.string().optional(),start_verification_session_url:E.string().url().optional(),checkout_payment_method_fields:E.array(E.object({type:E.union([E.literal("string"),E.literal("number"),E.literal("boolean")]),required:E.boolean(),key:E.string()})).max(qv,`The extension can't have more than ${qv} checkout_payment_method_fields`).optional()}).refine(e=>e.supports_installments===e.supports_deferred_payments,{message:"supports_installments and supports_deferred_payments must be the same"});function ste(e,t){let r=Ei(e,t);return{api_version:e.api_version,payment_session_url:e.start_payment_session_url,refund_session_url:e.start_refund_session_url,capture_session_url:e.start_capture_session_url,void_session_url:e.start_void_session_url,confirmation_callback_url:e.confirmation_callback_url,update_payment_session_url:e.update_payment_session_url,start_verification_session_url:e.start_verification_session_url,merchant_label:e.merchant_label,supports_oversell_protection:e.supports_oversell_protection,supports_3ds:e.supports_3ds,supports_installments:e.supports_installments,supports_deferred_payments:e.supports_deferred_payments,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,multiple_capture:e.multiple_capture,buyer_label:e.default_buyer_label,buyer_label_translations:e.buyer_label_to_locale,checkout_payment_method_fields:e.checkout_payment_method_fields,modal_payment_method_fields:e.modal_payment_method_fields,ui_extension_handle:r}}async function Hv(e){return{api_version:e.api_version,start_payment_session_url:e.payment_session_url,start_refund_session_url:e.refund_session_url,start_capture_session_url:e.capture_session_url,start_void_session_url:e.void_session_url,confirmation_callback_url:e.confirmation_callback_url,update_payment_session_url:e.update_payment_session_url,start_verification_session_url:e.start_verification_session_url,merchant_label:e.merchant_label,supports_oversell_protection:e.supports_oversell_protection,supports_3ds:e.supports_3ds,supports_installments:e.supports_installments,supports_deferred_payments:e.supports_deferred_payments,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,multiple_capture:e.multiple_capture,default_buyer_label:e.buyer_label,buyer_label_to_locale:e.buyer_label_translations,checkout_payment_method_fields:e.checkout_payment_method_fields,modal_payment_method_fields:e.modal_payment_method_fields,ui_extension_handle:e.ui_extension_handle}}d();var Ih="payments.custom-credit-card.render",zv=7,Vv=Fr.merge(yi).merge(Fi).merge(Dn).required({refund_session_url:!0,capture_session_url:!0,void_session_url:!0}).extend({targeting:E.array(E.object({target:E.literal(Ih)})).length(1),api_version:E.string(),multiple_capture:E.boolean(),checkout_hosted_fields:E.array(E.string()).optional(),ui_extension_handle:E.string().optional(),encryption_certificate_fingerprint:E.string(),checkout_payment_method_fields:E.array(E.object({type:E.union([E.literal("string"),E.literal("number"),E.literal("boolean")]),required:E.boolean(),key:E.string()})).max(zv,`The extension can't have more than ${zv} checkout_payment_method_fields`).optional()});function dte(e,t){let r=Ei(e,t);return{api_version:e.api_version,payment_session_url:e.start_payment_session_url,refund_session_url:e.start_refund_session_url,capture_session_url:e.start_capture_session_url,void_session_url:e.start_void_session_url,confirmation_callback_url:e.confirmation_callback_url,merchant_label:e.merchant_label,supports_3ds:e.supports_3ds,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,buyer_label:e.default_buyer_label,buyer_label_translations:e.buyer_label_to_locale,encryption_certificate_fingerprint:e.encryption_certificate.fingerprint,test_mode_available:e.test_mode_available,multiple_capture:e.multiple_capture,checkout_payment_method_fields:e.checkout_payment_method_fields,checkout_hosted_fields:e.checkout_hosted_fields,ui_extension_handle:r}}async function Gv(e){return{api_version:e.api_version,start_payment_session_url:e.payment_session_url,start_refund_session_url:e.refund_session_url,start_capture_session_url:e.capture_session_url,start_void_session_url:e.void_session_url,confirmation_callback_url:e.confirmation_callback_url,merchant_label:e.merchant_label,supports_3ds:e.supports_3ds,supported_countries:e.supported_countries,supported_buyer_contexts:e.supported_buyer_contexts,default_buyer_label:e.buyer_label,buyer_label_to_locale:e.buyer_label_translations,encryption_certificate_fingerprint:e.encryption_certificate_fingerprint,supported_payment_methods:e.supported_payment_methods,test_mode_available:e.test_mode_available,multiple_capture:e.multiple_capture,checkout_payment_method_fields:e.checkout_payment_method_fields,checkout_hosted_fields:e.checkout_hosted_fields,ui_extension_handle:e.ui_extension_handle}}d();var Bh="payments.credit-card.render",Kv=7,Jv=Fr.merge(nu).merge(Fi).merge(El).merge(Dn).required({refund_session_url:!0,capture_session_url:!0,void_session_url:!0}).extend({targeting:E.array(E.object({target:E.literal(Bh)})).length(1),verification_session_url:E.string().url().optional(),ui_extension_handle:E.string().optional(),supports_moto:E.boolean({required_error:"supports_moto is required",invalid_type_error:"Value must be Boolean"}),encryption_certificate_fingerprint:E.string(),checkout_payment_method_fields:E.array(E.object({type:E.union([E.literal("string"),E.literal("number"),E.literal("boolean")]),required:E.boolean(),key:E.string()})).max(Kv,`The extension can't have more than ${Kv} checkout_payment_method_fields`).optional()}).refine(e=>!e.supports_3ds||e.confirmation_callback_url,{message:"Property required when supports_3ds is true",path:["confirmation_callback_url"]}).refine(e=>e.supports_installments===e.supports_deferred_payments,{message:"supports_installments and supports_deferred_payments must be the same"});function yte(e,t){let r=Ei(e,t);return{api_version:e.api_version,payment_session_url:e.start_payment_session_url,refund_session_url:e.start_refund_session_url,capture_session_url:e.start_capture_session_url,void_session_url:e.start_void_session_url,confirmation_callback_url:e.confirmation_callback_url,multiple_capture:e.multiple_capture,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,supports_3ds:e.supports_3ds,supports_moto:e.supports_moto,supports_deferred_payments:e.supports_deferred_payments,supports_installments:e.supports_installments,verification_session_url:e.start_verification_session_url,encryption_certificate_fingerprint:e.encryption_certificate.fingerprint,checkout_payment_method_fields:e.checkout_payment_method_fields,ui_extension_handle:r}}async function Yv(e){return{api_version:e.api_version,start_payment_session_url:e.payment_session_url,start_refund_session_url:e.refund_session_url,start_capture_session_url:e.capture_session_url,start_void_session_url:e.void_session_url,confirmation_callback_url:e.confirmation_callback_url,multiple_capture:e.multiple_capture,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,supported_buyer_contexts:e.supported_buyer_contexts,test_mode_available:e.test_mode_available,supports_3ds:e.supports_3ds,supports_moto:e.supports_moto,supports_deferred_payments:e.supports_deferred_payments,encryption_certificate_fingerprint:e.encryption_certificate_fingerprint,supports_installments:e.supports_installments,start_verification_session_url:e.verification_session_url,checkout_payment_method_fields:e.checkout_payment_method_fields,ui_extension_handle:e.ui_extension_handle}}d();var Rh="payments.card-present.render",Xv=Fr.required({refund_session_url:!0,capture_session_url:!0,void_session_url:!0}).extend({targeting:E.array(E.object({target:E.literal(Rh)})).length(1),sync_terminal_transaction_result_url:E.string().url().optional()});function wte(e){return{api_version:e.api_version,payment_session_url:e.start_payment_session_url,refund_session_url:e.start_refund_session_url,capture_session_url:e.start_capture_session_url,void_session_url:e.start_void_session_url,sync_terminal_transaction_result_url:e.sync_terminal_transaction_result_url,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,test_mode_available:e.test_mode_available}}async function Zv(e){return{api_version:e.api_version,start_payment_session_url:e.payment_session_url,start_refund_session_url:e.refund_session_url,start_capture_session_url:e.capture_session_url,start_void_session_url:e.void_session_url,sync_terminal_transaction_result_url:e.sync_terminal_transaction_result_url,merchant_label:e.merchant_label,supported_countries:e.supported_countries,supported_payment_methods:e.supported_payment_methods,test_mode_available:e.test_mode_available}}var gN=E.union([$v,Uv,Wv,Vv,Jv,Xv]),_N=Ie({identifier:"payments_extension",schema:gN,appModuleFeatures:e=>[],deployConfig:async(e,t)=>{switch(e.targeting[0]?.target){case Ph:return Lv(e);case Oh:return kv(e);case Bh:return Yv(e);case Th:return Hv(e);case Ih:return Gv(e);case Rh:return Zv(e);default:return{}}}}),Qv=_N;d();var Nh="@shopify/retail-ui-extensions",yN=Ke.extend({name:E.string()}),FN=Ie({identifier:"pos_ui_extension",dependency:Nh,schema:yN,appModuleFeatures:e=>["ui_preview","esbuild","single_js_entry_path"],getOutputRelativePath:e=>`dist/${e.handle}.js`,clientSteps:[{lifecycle:"deploy",steps:[{id:"bundle-ui",name:"Bundle UI Extension",type:"bundle_ui",config:{}}]}],deployConfig:async(e,t)=>{let r=await Ts(Nh,t);if(r==="not_found")throw new Mr(`Dependency ${Nh} not found`);return{name:e.name,description:e.description,renderer_version:r?.version}}}),eC=FN;d();var Mh="@shopify/admin-ui-extensions",EN=Ie({identifier:"product_subscription",additionalIdentifiers:["subscription_management"],dependency:Mh,graphQLType:"subscription_management",schema:Ke,appModuleFeatures:e=>["ui_preview","esbuild","single_js_entry_path"],getOutputRelativePath:e=>`dist/${e.handle}.js`,clientSteps:[{lifecycle:"deploy",steps:[{id:"bundle-ui",name:"Bundle UI Extension",type:"bundle_ui",config:{}}]}],deployConfig:async(e,t)=>{let r=await Ts(Mh,t);if(r==="not_found")throw new Mr(`Dependency ${Mh} not found`);return{renderer_version:r?.version}}}),tC=EN;d();var vN=E.object({key:E.string()}),CN=Ke.extend({production_api_base_url:E.string(),benchmark_api_base_url:E.string().optional(),calculate_taxes_api_endpoint:E.string(),input:E.object({metafield_identifiers:E.object({namespace:E.string(),key:E.string()}).optional()}).optional(),metafields:E.array(mi).optional(),cart_line_properties:E.array(vN).optional()}),wN=Ie({identifier:"tax_calculation",schema:CN,appModuleFeatures:e=>[],getOutputRelativePath:e=>B("dist",`${e.handle}.js`),clientSteps:[{lifecycle:"deploy",steps:[{id:"create-tax-stub",name:"Create Tax Stub",type:"create_tax_stub",config:{}}]}],deployConfig:async(e,t)=>({production_api_base_url:e.production_api_base_url,benchmark_api_base_url:e.benchmark_api_base_url,calculate_taxes_api_endpoint:e.calculate_taxes_api_endpoint,metafields:e.metafields,cart_line_properties:e.cart_line_properties,api_version:e.api_version,metafield_identifiers:e.input?.metafield_identifiers})}),rC=wN;d();var bN=Ie({identifier:"theme",schema:Ke,partnersWebIdentifier:"theme_app_extension",graphQLType:"theme_app_extension",clientSteps:[{lifecycle:"deploy",steps:[{id:"build-theme",name:"Build Theme Extension",type:"build_theme",config:{}},{id:"bundle-theme",name:"Bundle Theme Extension",type:"bundle_theme",config:{}}]}],appModuleFeatures:e=>["theme"],deployConfig:async()=>({theme_extension:{files:{}}}),preDeployValidation:async e=>xN(e)}),sC=bN,jh=1024,aC=jh*1024,cC=10,AN=cC*aC,lC=500,SN=lC*jh,nC=[".jpg",".jpeg",".json",".js",".css",".png",".svg",".wasm"],iC=[".json"],fC={assets:{validator:new RegExp(`${nC.join("|")}$`),failureMessage:e=>`Only these filetypes are supported in assets: ${nC.join(", ")}`},blocks:{validator:/.liquid$/,failureMessage:e=>"Only .liquid files are allowed in blocks."},locales:{validator:new RegExp(`${iC.join("|")}$`),failureMessage:e=>`Only these filetypes are supported in locales: ${iC.join(", ")}`},snippets:{validator:/.liquid$/,failureMessage:e=>"Only .liquid files are allowed in snippets."}},oC=Object.keys(fC);async function xN(e){let t=await bs(e),r=[],n=[];await Promise.all(t.map(async o=>{let s=Te(e.directory,o),a=De(s);TN(s,a);let l=await Sc(o);n.push(l),["blocks","snippets"].includes(a)&&r.push(l)})),PN(uC(n)),ON(uC(r))}function PN(e){if(e>AN){let t=`${(e/aC).toFixed(2)} MB`;throw new k(`Your theme app extension exceeds the file size limit (${cC} MB). It's currently ${t}.`,"Reduce your total file size and try again.")}}function ON(e){if(e>SN){let t=`${(e/jh).toFixed(2)} kB`;throw new k(`Your theme app extension exceeds the total liquid file size limit (${lC} kB). It's currently ${t}.`,"Reduce your total file size and try again.")}}function TN(e,t){if(!oC.includes(t))throw new k(Se`Your theme app extension includes files in an unsupported directory, ${Ae.path(t)}`,`Make sure all theme app extension files are in the supported directories: ${oC.join(", ")}`);let r=fC[t];if(!e.match(r.validator))throw new k(`Invalid filename in your theme app extension: ${e}
250
- ${r.failureMessage(e)}`)}function uC(e){return e.reduce((t,r)=>t+r,0)}d();d();var H2=fi(RD(),1);import{createRequire as IU}from"module";async function wm(){let e=await import("./typescript-5R4Y7PXE.js");return e.default??e}var q2=IU(import.meta.url),W2="@shopify/ui-extensions";function BU(e){let t=e.toLowerCase().replace(/(::|\.).+$/,"");switch(t){case"purchase":return"checkout";case"pos":return"point-of-sale";default:return t}}function bm(e){let t=e[0];return t?`${W2}/${BU(t)}`:W2}function aa(e){let[t,r]=e.split("-");return!t||!r?null:{year:parseInt(t,10),month:parseInt(r,10)}}async function z2(e,t){let r=await wm(),n=r.findConfigFile(e,r.sys.fileExists.bind(r.sys),"tsconfig.json");if(!n)return{compilerOptions:{},configPath:void 0,hasExplicitFiles:!1};let o=ot(n),s=t?.get(o);if(s)return s;let a=r.readConfigFile(n,r.sys.readFile.bind(r.sys));if(a.error)return{compilerOptions:{},configPath:o,hasExplicitFiles:!1};let l=r.parseJsonConfigFileContent(a.config,r.sys,De(n)),p=!!(l.raw?.files??l.raw?.include),D={compilerOptions:l.options,configPath:o,fileNames:l.fileNames,hasExplicitFiles:p};return t?.set(o,D),D}async function RU(e,t){if(!e.startsWith("./")&&!e.startsWith("../"))return null;let r=ot(t,e),n=["",".js",".jsx",".ts",".tsx"];for(let o of n){let s=r+o;if(await Y(s)&&!s.includes("node_modules"))return s}for(let o of[".js",".jsx",".ts",".tsx"]){let s=B(r,`index${o}`);if(await Y(s)&&!s.includes("node_modules"))return s}return null}function V2(e){return e.length>0&&e.every(t=>t.isTypeOnly)}function NU(e,t){if(e.importClause?.isTypeOnly)return!0;let r=e.importClause?.namedBindings;return e.importClause?.name||!r?!1:t.isNamedImports(r)&&V2(r.elements)}function MU(e,t){if(e.isTypeOnly)return!0;let r=e.exportClause;return r?t.isNamedExports(r)&&V2(r.elements):!1}function jU(e,t){return t?my(ot(t),ot(e)):!0}function $U(e,t){if(!t.allowedFiles)return!0;let r=ot(e);return t.allowedFiles.has(r)||!!t.alwaysAllowedFiles?.has(r)}function G2(e,t){return!e.includes("node_modules")&&!e.endsWith(".d.ts")&&$U(e,t)}function LU(e,t){let r=ot(e),n=(t.allowedFiles?.has(r)??!1)||(t.alwaysAllowedFiles?.has(r)??!1);return G2(e,t)&&(jU(e,t.boundaryDirectory)||n)}async function UU(e,t={}){try{let r=ot(e),n=t.importCache?.get(r);if(n)return n;let o=await wm(),s=to(e).toString(),a=[],{compilerOptions:l}=await z2(e,t.tsConfigCache),p=o.ScriptKind.JSX;e.endsWith(".ts")?p=o.ScriptKind.TS:e.endsWith(".tsx")&&(p=o.ScriptKind.TSX);let D=o.createSourceFile(e,s,o.ScriptTarget.Latest,!0,p),g=new Set,F=[],w=v=>{if(o.isImportDeclaration(v)&&v.moduleSpecifier&&o.isStringLiteral(v.moduleSpecifier)){if(NU(v,o))return;F.push(v.moduleSpecifier.text)}else if(o.isCallExpression(v)&&v.expression.kind===o.SyntaxKind.ImportKeyword){let S=v.arguments[0];S&&o.isStringLiteral(S)&&F.push(S.text)}else if(o.isExportDeclaration(v)&&v.moduleSpecifier&&o.isStringLiteral(v.moduleSpecifier)){if(MU(v,o))return;F.push(v.moduleSpecifier.text)}o.forEachChild(v,w)};w(D);for(let v of F){if(!v||g.has(v))continue;g.add(v);let S=o.resolveModuleName(v,e,l,o.sys);if(S.resolvedModule?.resolvedFileName){let O=S.resolvedModule.resolvedFileName;O.includes("node_modules")||a.push(O)}else{let O=await RU(v,De(e));O&&a.push(O)}}return t.importCache?.set(r,a),a}catch(r){if(r instanceof k)throw r;return[]}}async function Df(e,t={},r=new Set){if(r.has(e))return[];r.add(e);let n=(await UU(e,t)).filter(s=>G2(s,t)),o=[...n];for(let s of n){if(!LU(s,t))continue;let a=await Df(s,t,r);o.push(...a)}return Bt(o)}async function Am(e,t,r={}){let{configPath:n,fileNames:o,hasExplicitFiles:s}=await z2(e,r.tsConfigCache);if(!(!n||!s))return new Set((o??[]).map(a=>ot(a)))}async function kU(e){let t;try{t=to(e).toString()}catch{return!1}let r=await wm(),n=r.createSourceFile(e,t,r.ScriptTarget.Latest,!0,r.ScriptKind.TS),o=!1,s=a=>{if(!o){if(r.isExportDeclaration(a)&&a.exportClause&&r.isNamedExports(a.exportClause)){for(let l of a.exportClause.elements)if(l.name.text==="ShopifyGlobal"){o=!0;return}}r.forEachChild(a,s)}};return s(n),o}async function qU(e,t){let r=async n=>{let o=`import('@shopify/ui-extensions/${n}').Api`,s=t.get(n);return s&&await kU(s)?`${o} & import('@shopify/ui-extensions/${n}').ShopifyGlobal`:o};return e.length===1?r(e[0]??""):e.length>1?`(${(await Promise.all(e.map(r))).join(" | ")})`:null}async function WU(e,t,{includesTools:r,includesIntents:n},o){let s=await qU(e,t);if(!s)return null;if(!r&&!n)return s;let a=s;return n&&(a=`import('${o}').WithGeneratedIntents<${a}, ShopifyGeneratedIntentVariants>`),r&&(a=`import('${o}').WithGeneratedTools<${a}, ShopifyTools>`),a}async function K2({fullPath:e,typeFilePath:t,targets:r,apiVersion:n,toolsTypeDefinition:o,intentsTypeDefinition:s}){try{let a=new Map,l=!!o,p=!!s;for(let v of r)try{let S=q2.resolve(`@shopify/ui-extensions/${v}`,{paths:[e,t]});a.set(v,S)}catch{let{year:O,month:P}=aa(n)??{year:2025,month:10};throw new k(`Type reference for ${v} could not be found. You might be using the wrong @shopify/ui-extensions version.`,`Fix the error by ensuring you have the correct version of @shopify/ui-extensions, for example ~${O}.${P}.0, in your dependencies.`)}let D=bm(r);if(l||p)try{q2.resolve(D,{paths:[e,t]})}catch{let{year:S,month:O}=aa(n)??{year:2025,month:10};throw new k(`Type reference for ${D} could not be found. You might be using the wrong @shopify/ui-extensions version.`,`Fix the error by ensuring you have the correct version of @shopify/ui-extensions, for example ~${S}.${O}.0, in your dependencies.`)}let g=wc(e,De(t)),F=await WU(r,a,{includesTools:l,includesIntents:p},D);return F?["//@ts-ignore",`declare module './${g}' {`,...o?[o]:[],...s?[s]:[],` const shopify: ${F};`," const globalThis: { shopify: typeof shopify };","}",""].join(`
250
+ ${r.failureMessage(e)}`)}function uC(e){return e.reduce((t,r)=>t+r,0)}d();d();var H2=fi(RD(),1);import{createRequire as IU}from"module";async function wm(){let e=await import("./typescript-ISACCMJN.js");return e.default??e}var q2=IU(import.meta.url),W2="@shopify/ui-extensions";function BU(e){let t=e.toLowerCase().replace(/(::|\.).+$/,"");switch(t){case"purchase":return"checkout";case"pos":return"point-of-sale";default:return t}}function bm(e){let t=e[0];return t?`${W2}/${BU(t)}`:W2}function aa(e){let[t,r]=e.split("-");return!t||!r?null:{year:parseInt(t,10),month:parseInt(r,10)}}async function z2(e,t){let r=await wm(),n=r.findConfigFile(e,r.sys.fileExists.bind(r.sys),"tsconfig.json");if(!n)return{compilerOptions:{},configPath:void 0,hasExplicitFiles:!1};let o=ot(n),s=t?.get(o);if(s)return s;let a=r.readConfigFile(n,r.sys.readFile.bind(r.sys));if(a.error)return{compilerOptions:{},configPath:o,hasExplicitFiles:!1};let l=r.parseJsonConfigFileContent(a.config,r.sys,De(n)),p=!!(l.raw?.files??l.raw?.include),D={compilerOptions:l.options,configPath:o,fileNames:l.fileNames,hasExplicitFiles:p};return t?.set(o,D),D}async function RU(e,t){if(!e.startsWith("./")&&!e.startsWith("../"))return null;let r=ot(t,e),n=["",".js",".jsx",".ts",".tsx"];for(let o of n){let s=r+o;if(await Y(s)&&!s.includes("node_modules"))return s}for(let o of[".js",".jsx",".ts",".tsx"]){let s=B(r,`index${o}`);if(await Y(s)&&!s.includes("node_modules"))return s}return null}function V2(e){return e.length>0&&e.every(t=>t.isTypeOnly)}function NU(e,t){if(e.importClause?.isTypeOnly)return!0;let r=e.importClause?.namedBindings;return e.importClause?.name||!r?!1:t.isNamedImports(r)&&V2(r.elements)}function MU(e,t){if(e.isTypeOnly)return!0;let r=e.exportClause;return r?t.isNamedExports(r)&&V2(r.elements):!1}function jU(e,t){return t?my(ot(t),ot(e)):!0}function $U(e,t){if(!t.allowedFiles)return!0;let r=ot(e);return t.allowedFiles.has(r)||!!t.alwaysAllowedFiles?.has(r)}function G2(e,t){return!e.includes("node_modules")&&!e.endsWith(".d.ts")&&$U(e,t)}function LU(e,t){let r=ot(e),n=(t.allowedFiles?.has(r)??!1)||(t.alwaysAllowedFiles?.has(r)??!1);return G2(e,t)&&(jU(e,t.boundaryDirectory)||n)}async function UU(e,t={}){try{let r=ot(e),n=t.importCache?.get(r);if(n)return n;let o=await wm(),s=to(e).toString(),a=[],{compilerOptions:l}=await z2(e,t.tsConfigCache),p=o.ScriptKind.JSX;e.endsWith(".ts")?p=o.ScriptKind.TS:e.endsWith(".tsx")&&(p=o.ScriptKind.TSX);let D=o.createSourceFile(e,s,o.ScriptTarget.Latest,!0,p),g=new Set,F=[],w=v=>{if(o.isImportDeclaration(v)&&v.moduleSpecifier&&o.isStringLiteral(v.moduleSpecifier)){if(NU(v,o))return;F.push(v.moduleSpecifier.text)}else if(o.isCallExpression(v)&&v.expression.kind===o.SyntaxKind.ImportKeyword){let S=v.arguments[0];S&&o.isStringLiteral(S)&&F.push(S.text)}else if(o.isExportDeclaration(v)&&v.moduleSpecifier&&o.isStringLiteral(v.moduleSpecifier)){if(MU(v,o))return;F.push(v.moduleSpecifier.text)}o.forEachChild(v,w)};w(D);for(let v of F){if(!v||g.has(v))continue;g.add(v);let S=o.resolveModuleName(v,e,l,o.sys);if(S.resolvedModule?.resolvedFileName){let O=S.resolvedModule.resolvedFileName;O.includes("node_modules")||a.push(O)}else{let O=await RU(v,De(e));O&&a.push(O)}}return t.importCache?.set(r,a),a}catch(r){if(r instanceof k)throw r;return[]}}async function Df(e,t={},r=new Set){if(r.has(e))return[];r.add(e);let n=(await UU(e,t)).filter(s=>G2(s,t)),o=[...n];for(let s of n){if(!LU(s,t))continue;let a=await Df(s,t,r);o.push(...a)}return Bt(o)}async function Am(e,t,r={}){let{configPath:n,fileNames:o,hasExplicitFiles:s}=await z2(e,r.tsConfigCache);if(!(!n||!s))return new Set((o??[]).map(a=>ot(a)))}async function kU(e){let t;try{t=to(e).toString()}catch{return!1}let r=await wm(),n=r.createSourceFile(e,t,r.ScriptTarget.Latest,!0,r.ScriptKind.TS),o=!1,s=a=>{if(!o){if(r.isExportDeclaration(a)&&a.exportClause&&r.isNamedExports(a.exportClause)){for(let l of a.exportClause.elements)if(l.name.text==="ShopifyGlobal"){o=!0;return}}r.forEachChild(a,s)}};return s(n),o}async function qU(e,t){let r=async n=>{let o=`import('@shopify/ui-extensions/${n}').Api`,s=t.get(n);return s&&await kU(s)?`${o} & import('@shopify/ui-extensions/${n}').ShopifyGlobal`:o};return e.length===1?r(e[0]??""):e.length>1?`(${(await Promise.all(e.map(r))).join(" | ")})`:null}async function WU(e,t,{includesTools:r,includesIntents:n},o){let s=await qU(e,t);if(!s)return null;if(!r&&!n)return s;let a=s;return n&&(a=`import('${o}').WithGeneratedIntents<${a}, ShopifyGeneratedIntentVariants>`),r&&(a=`import('${o}').WithGeneratedTools<${a}, ShopifyTools>`),a}async function K2({fullPath:e,typeFilePath:t,targets:r,apiVersion:n,toolsTypeDefinition:o,intentsTypeDefinition:s}){try{let a=new Map,l=!!o,p=!!s;for(let v of r)try{let S=q2.resolve(`@shopify/ui-extensions/${v}`,{paths:[e,t]});a.set(v,S)}catch{let{year:O,month:P}=aa(n)??{year:2025,month:10};throw new k(`Type reference for ${v} could not be found. You might be using the wrong @shopify/ui-extensions version.`,`Fix the error by ensuring you have the correct version of @shopify/ui-extensions, for example ~${O}.${P}.0, in your dependencies.`)}let D=bm(r);if(l||p)try{q2.resolve(D,{paths:[e,t]})}catch{let{year:S,month:O}=aa(n)??{year:2025,month:10};throw new k(`Type reference for ${D} could not be found. You might be using the wrong @shopify/ui-extensions version.`,`Fix the error by ensuring you have the correct version of @shopify/ui-extensions, for example ~${S}.${O}.0, in your dependencies.`)}let g=wc(e,De(t)),F=await WU(r,a,{includesTools:l,includesIntents:p},D);return F?["//@ts-ignore",`declare module './${g}' {`,...o?[o]:[],...s?[s]:[],` const shopify: ${F};`," const globalThis: { shopify: typeof shopify };","}",""].join(`
251
251
  `):null}catch(a){if(a instanceof k)throw a;let{year:l,month:p}=aa(n)??{year:2025,month:10};throw new k("Type reference could not be found. You might be using the wrong @shopify/ui-extensions version.",`Fix the error by ensuring you have the correct version of @shopify/ui-extensions, for example ~${l}.${p}.0, in your dependencies.`)}}async function J2(e,t){let r=De(e),n=await ln("tsconfig.json",{cwd:r,type:"file"});if(n){let o=ot(n),s=ot(t);if(o.startsWith(s))return De(n)}}var HU=E.object({name:E.string(),description:E.string(),inputSchema:E.object({}).passthrough(),outputSchema:E.object({}).passthrough().optional()}),Y2=E.array(HU),X2=E.object({value:E.object({}).passthrough().optional(),inputSchema:E.object({}).passthrough(),outputSchema:E.object({}).passthrough().optional()});function zU(e){return Wo(`${e.action} ${e.type}`.replace(/[^a-zA-Z0-9]+/g," "))}async function Z2(e,{generatedTypesHelperImportPath:t}){if(e.length===0)return"";let r=new Set,n=e.map(async a=>{let l=`${a.action}:${a.type}`;if(r.has(l))throw new k(`Intent "${l}" is defined multiple times. Intents must be unique within a target.`);r.add(l);let p=zU(a),D=`${p}IntentInput`,g=`${p}IntentValue`,F=`${p}IntentOutput`,w=`${p}IntentRequest`,v=await ca(D,a.inputSchema),S=await ca(g,a.valueSchema),O=await ca(F,a.outputSchema),P=`interface ${w} {
252
252
  action: ${JSON.stringify(a.action)};
253
253
  type: ${JSON.stringify(a.type)};
@@ -1 +1 @@
1
- import{a as i}from"./chunk-EVQPVO4P.js";import{b as e}from"./chunk-CUZQRXTV.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var t=class extends e{static description="View the UI kit components prompts";static hidden=!0;async run(){await i()}};export{t as a};
1
+ import{a as i}from"./chunk-4565O5TG.js";import{b as e}from"./chunk-EZ5F4ZFY.js";import{g as o}from"./chunk-VKWPEFWQ.js";o();var t=class extends e{static description="View the UI kit components prompts";static hidden=!0;async run(){await i()}};export{t as a};
@@ -1,4 +1,4 @@
1
- import{k as P,t as F}from"./chunk-NSHKVJST.js";import{a as N}from"./chunk-Q7BOSHWX.js";import{a as T}from"./chunk-ZQKZC2KN.js";import{I as H,K as q,k as $,pa as d,ra as h}from"./chunk-VWYZCCRE.js";import{a as x}from"./chunk-32B4LIKH.js";import{B as I,C as L,T as v}from"./chunk-KCHERKZO.js";import{i as l}from"./chunk-XUJURYN5.js";import{Cb as C,Eb as U,Nb as c}from"./chunk-COFGQT76.js";import{u as O}from"./chunk-C4QR7Z4N.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();p();function D(e){let t=new URLSearchParams;for(let[r,o]of Object.entries(e.replaceTemplates??[]))t.append(`replace_templates[${r}]`,o);for(let[r,o]of Object.entries(e.replaceExtensionTemplates??[])){let n=r.split("/")[0];t.append(`replace_extension_templates[${n}][${r}]`,o)}return t.append("_method",e.method),t}function w(){return{"User-Agent":`Shopify CLI; v=${x}`}}function k(e){return delete e.cookie,delete e.authorization,e}p();function S(e){let t={};return e.split(";").forEach(r=>{let o=r.match(/(.*?)=(.*)$/)??[],n=o[1]?.trim(),s=o[2]?.trim()??"";n&&(t[n]=s)}),t}function E(e){return Object.entries(e).map(([t,r])=>`${t}=${r}`).join("; ")}var y=class extends l{};async function Re(e){return F(e)}async function be(e,t,r){let o=M(t),n=new URLSearchParams;n.append("form_type","storefront_password"),n.append("utf8","\u2713"),n.append("password",e??""),h("theme-service:storefront-session:check-storefront-password");let s={"cache-control":"no-cache","content-type":"application/x-www-form-urlencoded",...r},a=await $(`${o}/password`,{headers:s,body:n.toString(),method:"POST",redirect:"manual"});if(a.status===429)throw d(new l(`Too many incorrect password attempts. Please try again after ${a.headers.get("retry-after")} seconds.`));return B(a,o)}async function j(e,t,r,o,n={}){let s={},a=await G(e,r,n),i=M(t);if(s._shopify_essential=a,h(`theme-service:storefront-session:is-password-protected:${!!o}`),!o)return s;let u=await ee(a,e,i,o,n);return{...s,...u}}async function G(e,t,r,o=1){let n=new URLSearchParams({preview_theme_id:t,_fd:"0",pb:"0"}),s=`${e}?${n}`;h("theme-service:storefront-session:get-session-essential-cookie");let a={...r,...w()},i=await $(s,{method:"HEAD",redirect:"manual",headers:a}),u=i.headers.raw()["set-cookie"]??[],f=_(u,"_shopify_essential");if(!f){if(c(`Failed to obtain _shopify_essential cookie.
1
+ import{k as P,t as F}from"./chunk-JAY7AGAG.js";import{a as N}from"./chunk-Q7BOSHWX.js";import{a as T}from"./chunk-DH5E6NM3.js";import{I as H,K as q,k as $,pa as d,ra as h}from"./chunk-3E3MCY5O.js";import{a as x}from"./chunk-TQ7MHGY4.js";import{B as I,C as L,T as v}from"./chunk-RCYQPOJW.js";import{i as l}from"./chunk-ZZ7SOJHH.js";import{Cb as C,Eb as U,Nb as c}from"./chunk-3F42A3XV.js";import{u as O}from"./chunk-2R2PKQQV.js";import{g as p}from"./chunk-VKWPEFWQ.js";p();p();function D(e){let t=new URLSearchParams;for(let[r,o]of Object.entries(e.replaceTemplates??[]))t.append(`replace_templates[${r}]`,o);for(let[r,o]of Object.entries(e.replaceExtensionTemplates??[])){let n=r.split("/")[0];t.append(`replace_extension_templates[${n}][${r}]`,o)}return t.append("_method",e.method),t}function w(){return{"User-Agent":`Shopify CLI; v=${x}`}}function k(e){return delete e.cookie,delete e.authorization,e}p();function S(e){let t={};return e.split(";").forEach(r=>{let o=r.match(/(.*?)=(.*)$/)??[],n=o[1]?.trim(),s=o[2]?.trim()??"";n&&(t[n]=s)}),t}function E(e){return Object.entries(e).map(([t,r])=>`${t}=${r}`).join("; ")}var y=class extends l{};async function Re(e){return F(e)}async function be(e,t,r){let o=M(t),n=new URLSearchParams;n.append("form_type","storefront_password"),n.append("utf8","\u2713"),n.append("password",e??""),h("theme-service:storefront-session:check-storefront-password");let s={"cache-control":"no-cache","content-type":"application/x-www-form-urlencoded",...r},a=await $(`${o}/password`,{headers:s,body:n.toString(),method:"POST",redirect:"manual"});if(a.status===429)throw d(new l(`Too many incorrect password attempts. Please try again after ${a.headers.get("retry-after")} seconds.`));return B(a,o)}async function j(e,t,r,o,n={}){let s={},a=await G(e,r,n),i=M(t);if(s._shopify_essential=a,h(`theme-service:storefront-session:is-password-protected:${!!o}`),!o)return s;let u=await ee(a,e,i,o,n);return{...s,...u}}async function G(e,t,r,o=1){let n=new URLSearchParams({preview_theme_id:t,_fd:"0",pb:"0"}),s=`${e}?${n}`;h("theme-service:storefront-session:get-session-essential-cookie");let a={...r,...w()},i=await $(s,{method:"HEAD",redirect:"manual",headers:a}),u=i.headers.raw()["set-cookie"]??[],f=_(u,"_shopify_essential");if(!f){if(c(`Failed to obtain _shopify_essential cookie.
2
2
 
3
3
  -Request ID: ${i.headers.get("x-request-id")??"unknown"}
4
4