@wix/cli 1.1.132 → 1.1.134

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 (185) hide show
  1. package/build/{DevCommand-36D5RTIS.js → DevCommand-4OQRGGV3.js} +15 -15
  2. package/build/DevCommand-NTBBKMAA.js +815 -0
  3. package/build/DevCommand-NTBBKMAA.js.map +1 -0
  4. package/build/{DevCommand-C6BQYRFU.js → DevCommand-WSXE72JB.js} +19 -19
  5. package/build/{EnvPullCommand-MIAEMMW7.js → EnvPullCommand-FSET3QAR.js} +12 -12
  6. package/build/{EnvRemoveCommand-4PM5K3WI.js → EnvRemoveCommand-FT5NPEKI.js} +11 -11
  7. package/build/{EnvSetCommand-VKDYZZXD.js → EnvSetCommand-7LPLV7GL.js} +11 -11
  8. package/build/{GenerateCommand-2YN6H45L.js → GenerateCommand-WI7ILK6G.js} +112 -107
  9. package/build/GenerateCommand-WI7ILK6G.js.map +1 -0
  10. package/build/{InstallCommand-AHGIP2UM.js → InstallCommand-DGPPZHXV.js} +17 -17
  11. package/build/{LoginCommand-WF6TT7QV.js → LoginCommand-VKQBW5EI.js} +9 -9
  12. package/build/{LogoutCommand-GHUHYROA.js → LogoutCommand-NKY5NWUQ.js} +6 -6
  13. package/build/{PreviewCommand-K67N3DXU.js → PreviewCommand-VQCQDGJ2.js} +19 -19
  14. package/build/{PreviewCommand-PYVWQY6C.js → PreviewCommand-W22KLFOH.js} +16 -14
  15. package/build/{PreviewCommand-WZDNMLQR.js → PreviewCommand-X7P2AHBY.js} +19 -19
  16. package/build/{PromoteCommand-2NQ7ROC6.js → PromoteCommand-VDTCKRE4.js} +16 -14
  17. package/build/{PromoteCommand-2NQ7ROC6.js.map → PromoteCommand-VDTCKRE4.js.map} +1 -1
  18. package/build/{PublishCommand-FWLZ4Q7B.js → PublishCommand-3MDL6QC4.js} +19 -19
  19. package/build/ReleaseCommand-TP4LUVYC.js +464 -0
  20. package/build/ReleaseCommand-TP4LUVYC.js.map +1 -0
  21. package/build/{UninstallCommand-ATJIJUYX.js → UninstallCommand-YPZPH7PM.js} +17 -17
  22. package/build/{WhoamiCommand-DVII27HG.js → WhoamiCommand-H4GCFFMW.js} +3 -3
  23. package/build/{chunk-SDCA2ZYO.js → chunk-26B5E4UO.js} +2 -2
  24. package/build/chunk-2IJTJJEM.js +29 -0
  25. package/build/chunk-2IJTJJEM.js.map +1 -0
  26. package/build/{chunk-PQYPUILG.js → chunk-34MTX547.js} +3 -3
  27. package/build/{chunk-LFW57BYP.js → chunk-3DWQFSNW.js} +3 -3
  28. package/build/{chunk-3UICD2U3.js → chunk-3RVONWI7.js} +2 -2
  29. package/build/{chunk-L7OWQEI4.js → chunk-4QGQ7FU5.js} +3 -3
  30. package/build/{chunk-OKM7KSQY.js → chunk-5OQDBYCC.js} +6 -6
  31. package/build/{DevCommand-XWXE2GQD.js → chunk-5Z6Q4IJX.js} +1299 -1261
  32. package/build/chunk-5Z6Q4IJX.js.map +1 -0
  33. package/build/{chunk-KZY33NY5.js → chunk-66VZCA5Y.js} +6 -6
  34. package/build/{chunk-ULFNXCSJ.js → chunk-6GSUU65D.js} +2 -2
  35. package/build/{chunk-NIEDH7Z5.js → chunk-6XQIBCEG.js} +4 -4
  36. package/build/{chunk-NUKGEVK2.js → chunk-763CNX5X.js} +2 -2
  37. package/build/chunk-BAXAZXTT.js +144 -0
  38. package/build/chunk-BAXAZXTT.js.map +1 -0
  39. package/build/{chunk-R7IJZ53U.js → chunk-BEKFXS6A.js} +32 -32
  40. package/build/chunk-BEKFXS6A.js.map +1 -0
  41. package/build/{chunk-TEHIT3JS.js → chunk-CU77QH5G.js} +3 -2
  42. package/build/{chunk-TEHIT3JS.js.map → chunk-CU77QH5G.js.map} +1 -1
  43. package/build/{chunk-OBQKLL5P.js → chunk-DQULLGU7.js} +68 -8
  44. package/build/chunk-DQULLGU7.js.map +1 -0
  45. package/build/{chunk-ZBIKOMT2.js → chunk-DTJ6JGVE.js} +8 -8
  46. package/build/{chunk-7LW7GOIM.js → chunk-EYBSRZFX.js} +4 -4
  47. package/build/{chunk-MTHAQUUR.js → chunk-HGBT2YDL.js} +5 -5
  48. package/build/{chunk-ZOAQTBFU.js → chunk-HZRGNT6A.js} +34 -14
  49. package/build/chunk-HZRGNT6A.js.map +1 -0
  50. package/build/{chunk-MXCQLS7U.js → chunk-JMUBTRYQ.js} +8 -8
  51. package/build/{chunk-JZSXLY7P.js → chunk-KFP5IROQ.js} +2 -2
  52. package/build/{chunk-PFESKRQ3.js → chunk-KJC2IRIO.js} +8 -8
  53. package/build/{chunk-VKQPC7RS.js → chunk-KRZQM5IB.js} +2 -2
  54. package/build/{chunk-BQQQEWSQ.js → chunk-KUETLEOF.js} +2 -2
  55. package/build/{chunk-72KSL2UL.js → chunk-LYSRG3GF.js} +4 -4
  56. package/build/{chunk-QGOR6CWP.js → chunk-MA6ZMAQU.js} +3 -3
  57. package/build/{chunk-G662LNCI.js → chunk-MT4UEZWE.js} +43 -14
  58. package/build/chunk-MT4UEZWE.js.map +1 -0
  59. package/build/{chunk-IXDWJCSQ.js → chunk-MWPS57J5.js} +7 -7
  60. package/build/{chunk-EBTHDX4J.js → chunk-N2YYKEKV.js} +3 -3
  61. package/build/{chunk-TFDYF6UW.js → chunk-OWJ2DBNB.js} +2 -2
  62. package/build/{chunk-RQWYBRCJ.js → chunk-OZKGZAOZ.js} +3 -3
  63. package/build/{chunk-P6JSJQO7.js → chunk-PBUFZ6OU.js} +4 -4
  64. package/build/{chunk-GKFBUNZ7.js → chunk-PDB7C6G4.js} +6 -6
  65. package/build/{chunk-H3ASS4MY.js → chunk-PETG4TB5.js} +5 -5
  66. package/build/{chunk-B5RG5HO2.js → chunk-PH4BOMTV.js} +3 -3
  67. package/build/{chunk-HOPIBYRH.js → chunk-POJ57ZT2.js} +178 -161
  68. package/build/chunk-POJ57ZT2.js.map +1 -0
  69. package/build/{chunk-B54YGGPW.js → chunk-QKIGR4DS.js} +8 -8
  70. package/build/{chunk-JRRYR6TL.js → chunk-QYUVUKJH.js} +3 -3
  71. package/build/{chunk-GQA35W2K.js → chunk-R5QQXCOY.js} +4 -4
  72. package/build/{chunk-GQA35W2K.js.map → chunk-R5QQXCOY.js.map} +1 -1
  73. package/build/{chunk-XOSGOQML.js → chunk-TL7UQCUX.js} +2 -2
  74. package/build/{chunk-TWJ2IXFS.js → chunk-VLGQTAVU.js} +8 -8
  75. package/build/chunk-XBR2M7HM.js +33 -0
  76. package/build/chunk-XBR2M7HM.js.map +1 -0
  77. package/build/{chunk-A2ZZA4JA.js → chunk-XEKM4VLO.js} +3 -3
  78. package/build/{chunk-NXZLDPHZ.js → chunk-XKEFEPF6.js} +2 -2
  79. package/build/{chunk-ZHZXA55V.js → chunk-YSTEUOSI.js} +2 -2
  80. package/build/{chunk-VJXBOXVQ.js → chunk-ZBGLF76X.js} +7 -7
  81. package/build/{dev-LMJBVIN6.js → dev-KS2OTEXB.js} +22 -22
  82. package/build/{env-pull-SZ3UP3AS.js → env-pull-DS57QSQI.js} +14 -14
  83. package/build/index.js +24 -24
  84. package/build/{install-W2S27UCI.js → install-XHQJGNSY.js} +15 -15
  85. package/build/{preview-UHUIYO6W.js → preview-CTFYUQYT.js} +18 -16
  86. package/build/{preview-UHUIYO6W.js.map → preview-CTFYUQYT.js.map} +1 -1
  87. package/build/{publish-BPUUEPHR.js → publish-UYXDXAJ2.js} +16 -16
  88. package/build/{render-command-KHMHOIGW.js → render-command-5VDNAXTP.js} +11 -11
  89. package/build/{render-command-5VWE3OKB.js → render-command-GC5M477M.js} +11 -11
  90. package/build/{render-command-2DXDNIXL.js → render-command-LZAIPJQS.js} +12 -12
  91. package/build/{render-command-IDDNHTNC.js → render-command-LZLXAPTJ.js} +12 -12
  92. package/build/{render-command-AMEJYHKN.js → render-command-ZYQ762CC.js} +11 -11
  93. package/build/{run-command-SGO33B4C.js → run-command-LY3OSHGO.js} +7 -7
  94. package/build/{src-FJVPEY4V.js → src-3KZZZJ3H.js} +14 -14
  95. package/build/{src-IEVBBVLL.js → src-6UQ5GS34.js} +6 -6
  96. package/build/{src-2UPI4DPW.js → src-6WPDBAIM.js} +39 -38
  97. package/build/{src-2UPI4DPW.js.map → src-6WPDBAIM.js.map} +1 -1
  98. package/build/{src-X52ZO3MD.js → src-ATQPFIAX.js} +4 -4
  99. package/build/{src-ZCXYT4MW.js → src-GA5OFATI.js} +4 -4
  100. package/build/{src-XCNX6HKZ.js → src-JP7XE6WI.js} +2 -2
  101. package/build/{src-3KXGLTSG.js → src-KS2HXFOE.js} +10 -8
  102. package/build/{src-2RGQFQKI.js → src-NXE7P7H4.js} +17 -17
  103. package/build/{sync-types-GL4WG3ZS.js → sync-types-B47N5WP2.js} +11 -11
  104. package/build/{uninstall-UW4USHS5.js → uninstall-2UZH5ABJ.js} +15 -15
  105. package/package.json +2 -2
  106. package/build/DevCommand-XWXE2GQD.js.map +0 -1
  107. package/build/GenerateCommand-2YN6H45L.js.map +0 -1
  108. package/build/ReleaseCommand-NADJCWXR.js +0 -184
  109. package/build/ReleaseCommand-NADJCWXR.js.map +0 -1
  110. package/build/chunk-G662LNCI.js.map +0 -1
  111. package/build/chunk-HOPIBYRH.js.map +0 -1
  112. package/build/chunk-OBQKLL5P.js.map +0 -1
  113. package/build/chunk-R7IJZ53U.js.map +0 -1
  114. package/build/chunk-YRI5HW7B.js +0 -857
  115. package/build/chunk-YRI5HW7B.js.map +0 -1
  116. package/build/chunk-ZOAQTBFU.js.map +0 -1
  117. /package/build/{DevCommand-36D5RTIS.js.map → DevCommand-4OQRGGV3.js.map} +0 -0
  118. /package/build/{DevCommand-C6BQYRFU.js.map → DevCommand-WSXE72JB.js.map} +0 -0
  119. /package/build/{EnvPullCommand-MIAEMMW7.js.map → EnvPullCommand-FSET3QAR.js.map} +0 -0
  120. /package/build/{EnvRemoveCommand-4PM5K3WI.js.map → EnvRemoveCommand-FT5NPEKI.js.map} +0 -0
  121. /package/build/{EnvSetCommand-VKDYZZXD.js.map → EnvSetCommand-7LPLV7GL.js.map} +0 -0
  122. /package/build/{InstallCommand-AHGIP2UM.js.map → InstallCommand-DGPPZHXV.js.map} +0 -0
  123. /package/build/{LoginCommand-WF6TT7QV.js.map → LoginCommand-VKQBW5EI.js.map} +0 -0
  124. /package/build/{LogoutCommand-GHUHYROA.js.map → LogoutCommand-NKY5NWUQ.js.map} +0 -0
  125. /package/build/{PreviewCommand-K67N3DXU.js.map → PreviewCommand-VQCQDGJ2.js.map} +0 -0
  126. /package/build/{PreviewCommand-PYVWQY6C.js.map → PreviewCommand-W22KLFOH.js.map} +0 -0
  127. /package/build/{PreviewCommand-WZDNMLQR.js.map → PreviewCommand-X7P2AHBY.js.map} +0 -0
  128. /package/build/{PublishCommand-FWLZ4Q7B.js.map → PublishCommand-3MDL6QC4.js.map} +0 -0
  129. /package/build/{UninstallCommand-ATJIJUYX.js.map → UninstallCommand-YPZPH7PM.js.map} +0 -0
  130. /package/build/{WhoamiCommand-DVII27HG.js.map → WhoamiCommand-H4GCFFMW.js.map} +0 -0
  131. /package/build/{chunk-SDCA2ZYO.js.map → chunk-26B5E4UO.js.map} +0 -0
  132. /package/build/{chunk-PQYPUILG.js.map → chunk-34MTX547.js.map} +0 -0
  133. /package/build/{chunk-LFW57BYP.js.map → chunk-3DWQFSNW.js.map} +0 -0
  134. /package/build/{chunk-3UICD2U3.js.map → chunk-3RVONWI7.js.map} +0 -0
  135. /package/build/{chunk-L7OWQEI4.js.map → chunk-4QGQ7FU5.js.map} +0 -0
  136. /package/build/{chunk-OKM7KSQY.js.map → chunk-5OQDBYCC.js.map} +0 -0
  137. /package/build/{chunk-KZY33NY5.js.map → chunk-66VZCA5Y.js.map} +0 -0
  138. /package/build/{chunk-ULFNXCSJ.js.map → chunk-6GSUU65D.js.map} +0 -0
  139. /package/build/{chunk-NIEDH7Z5.js.map → chunk-6XQIBCEG.js.map} +0 -0
  140. /package/build/{chunk-NUKGEVK2.js.map → chunk-763CNX5X.js.map} +0 -0
  141. /package/build/{chunk-ZBIKOMT2.js.map → chunk-DTJ6JGVE.js.map} +0 -0
  142. /package/build/{chunk-7LW7GOIM.js.map → chunk-EYBSRZFX.js.map} +0 -0
  143. /package/build/{chunk-MTHAQUUR.js.map → chunk-HGBT2YDL.js.map} +0 -0
  144. /package/build/{chunk-MXCQLS7U.js.map → chunk-JMUBTRYQ.js.map} +0 -0
  145. /package/build/{chunk-JZSXLY7P.js.map → chunk-KFP5IROQ.js.map} +0 -0
  146. /package/build/{chunk-PFESKRQ3.js.map → chunk-KJC2IRIO.js.map} +0 -0
  147. /package/build/{chunk-VKQPC7RS.js.map → chunk-KRZQM5IB.js.map} +0 -0
  148. /package/build/{chunk-BQQQEWSQ.js.map → chunk-KUETLEOF.js.map} +0 -0
  149. /package/build/{chunk-72KSL2UL.js.map → chunk-LYSRG3GF.js.map} +0 -0
  150. /package/build/{chunk-QGOR6CWP.js.map → chunk-MA6ZMAQU.js.map} +0 -0
  151. /package/build/{chunk-IXDWJCSQ.js.map → chunk-MWPS57J5.js.map} +0 -0
  152. /package/build/{chunk-EBTHDX4J.js.map → chunk-N2YYKEKV.js.map} +0 -0
  153. /package/build/{chunk-TFDYF6UW.js.map → chunk-OWJ2DBNB.js.map} +0 -0
  154. /package/build/{chunk-RQWYBRCJ.js.map → chunk-OZKGZAOZ.js.map} +0 -0
  155. /package/build/{chunk-P6JSJQO7.js.map → chunk-PBUFZ6OU.js.map} +0 -0
  156. /package/build/{chunk-GKFBUNZ7.js.map → chunk-PDB7C6G4.js.map} +0 -0
  157. /package/build/{chunk-H3ASS4MY.js.map → chunk-PETG4TB5.js.map} +0 -0
  158. /package/build/{chunk-B5RG5HO2.js.map → chunk-PH4BOMTV.js.map} +0 -0
  159. /package/build/{chunk-B54YGGPW.js.map → chunk-QKIGR4DS.js.map} +0 -0
  160. /package/build/{chunk-JRRYR6TL.js.map → chunk-QYUVUKJH.js.map} +0 -0
  161. /package/build/{chunk-XOSGOQML.js.map → chunk-TL7UQCUX.js.map} +0 -0
  162. /package/build/{chunk-TWJ2IXFS.js.map → chunk-VLGQTAVU.js.map} +0 -0
  163. /package/build/{chunk-A2ZZA4JA.js.map → chunk-XEKM4VLO.js.map} +0 -0
  164. /package/build/{chunk-NXZLDPHZ.js.map → chunk-XKEFEPF6.js.map} +0 -0
  165. /package/build/{chunk-ZHZXA55V.js.map → chunk-YSTEUOSI.js.map} +0 -0
  166. /package/build/{chunk-VJXBOXVQ.js.map → chunk-ZBGLF76X.js.map} +0 -0
  167. /package/build/{dev-LMJBVIN6.js.map → dev-KS2OTEXB.js.map} +0 -0
  168. /package/build/{env-pull-SZ3UP3AS.js.map → env-pull-DS57QSQI.js.map} +0 -0
  169. /package/build/{install-W2S27UCI.js.map → install-XHQJGNSY.js.map} +0 -0
  170. /package/build/{publish-BPUUEPHR.js.map → publish-UYXDXAJ2.js.map} +0 -0
  171. /package/build/{render-command-KHMHOIGW.js.map → render-command-5VDNAXTP.js.map} +0 -0
  172. /package/build/{render-command-5VWE3OKB.js.map → render-command-GC5M477M.js.map} +0 -0
  173. /package/build/{render-command-2DXDNIXL.js.map → render-command-LZAIPJQS.js.map} +0 -0
  174. /package/build/{render-command-IDDNHTNC.js.map → render-command-LZLXAPTJ.js.map} +0 -0
  175. /package/build/{render-command-AMEJYHKN.js.map → render-command-ZYQ762CC.js.map} +0 -0
  176. /package/build/{run-command-SGO33B4C.js.map → run-command-LY3OSHGO.js.map} +0 -0
  177. /package/build/{src-FJVPEY4V.js.map → src-3KZZZJ3H.js.map} +0 -0
  178. /package/build/{src-IEVBBVLL.js.map → src-6UQ5GS34.js.map} +0 -0
  179. /package/build/{src-3KXGLTSG.js.map → src-ATQPFIAX.js.map} +0 -0
  180. /package/build/{src-X52ZO3MD.js.map → src-GA5OFATI.js.map} +0 -0
  181. /package/build/{src-XCNX6HKZ.js.map → src-JP7XE6WI.js.map} +0 -0
  182. /package/build/{src-ZCXYT4MW.js.map → src-KS2HXFOE.js.map} +0 -0
  183. /package/build/{src-2RGQFQKI.js.map → src-NXE7P7H4.js.map} +0 -0
  184. /package/build/{sync-types-GL4WG3ZS.js.map → sync-types-B47N5WP2.js.map} +0 -0
  185. /package/build/{uninstall-UW4USHS5.js.map → uninstall-2UZH5ABJ.js.map} +0 -0
@@ -2,101 +2,69 @@ import { createRequire as _createRequire } from 'node:module';
2
2
  const require = _createRequire(import.meta.url);
3
3
  import {
4
4
  useDevCenterClient
5
- } from "./chunk-ZOAQTBFU.js";
6
- import {
7
- useTunnel
8
- } from "./chunk-GKFBUNZ7.js";
5
+ } from "./chunk-HZRGNT6A.js";
9
6
  import {
10
7
  wixCliAction,
11
- wixCliAppFlowFileUploadStarted,
12
- wixCliAppFlowStepsAnswers,
13
- wixCliAppFlowUploadEnded,
14
- wixCliAppsFlowDeploymentStatusSrc11Evid5232
8
+ wixCliAppFlowStepsAnswers
15
9
  } from "./chunk-LKYWHOMW.js";
16
- import {
17
- PlatformLink,
18
- useARMClient,
19
- useUpdateDeploymentTopology,
20
- useUpdateManifest
21
- } from "./chunk-YRI5HW7B.js";
22
- import {
23
- createPackageManager,
24
- getRepoType
25
- } from "./chunk-RQWYBRCJ.js";
26
- import {
27
- execa
28
- } from "./chunk-RWTQFIPN.js";
29
- import "./chunk-W54PG6O5.js";
30
10
  import {
31
11
  AlgorithmType,
12
+ BACKEND_WORKER_COMPONENT_ID,
32
13
  ComponentType,
33
14
  ElementType,
34
15
  EmbedCategory,
35
16
  EmbeddedScriptPlacement,
36
17
  PanelMode,
18
+ PlatformType,
37
19
  Width,
38
- devMetadataSchema,
39
- looseComponentSchema,
40
- parseLooseAppManifest,
20
+ deploymentTopologySchema,
21
+ getDeploymentTopologyPath,
41
22
  useProjectModel
42
- } from "./chunk-G662LNCI.js";
23
+ } from "./chunk-MT4UEZWE.js";
43
24
  import {
44
25
  useHttpClient
45
- } from "./chunk-3UICD2U3.js";
26
+ } from "./chunk-3RVONWI7.js";
46
27
  import {
47
28
  usePanoramaMethodLogger
48
- } from "./chunk-ULFNXCSJ.js";
29
+ } from "./chunk-6GSUU65D.js";
49
30
  import {
50
31
  BiProvider,
51
- ErrorViewer,
52
32
  SiteAuthProvider,
53
33
  TimeoutError,
34
+ isHttpError,
35
+ isHttpValidationError,
54
36
  openBrowser,
55
37
  pRetry,
56
38
  pWaitFor,
57
39
  resolveUrl,
58
40
  serializer,
59
41
  useBiLogger,
60
- useDebugLog,
61
- useErrorReporter
62
- } from "./chunk-OBQKLL5P.js";
63
- import "./chunk-WMCHVSMU.js";
42
+ useDebugLog
43
+ } from "./chunk-DQULLGU7.js";
64
44
  import {
65
45
  I18nProvider,
66
46
  Trans,
67
47
  useTranslation
68
- } from "./chunk-BQQQEWSQ.js";
69
- import "./chunk-KJ37XZQA.js";
48
+ } from "./chunk-KUETLEOF.js";
70
49
  import {
71
50
  Alert,
72
51
  Badge,
73
52
  Box_default,
74
- ConfirmInput,
75
53
  Key,
76
- PointerIcon,
54
+ Link,
55
+ PointerSmallIcon,
77
56
  SelectInput,
78
57
  SelectOptionAvailability,
79
58
  Spinner,
80
59
  Text,
81
- createRendererToString,
82
60
  useAsync,
83
61
  useAsyncCallback,
84
62
  useExit,
85
63
  use_input_default
86
- } from "./chunk-HOPIBYRH.js";
64
+ } from "./chunk-POJ57ZT2.js";
87
65
  import {
88
66
  require_react
89
67
  } from "./chunk-NRAQAV6T.js";
90
- import {
91
- stripAnsi
92
- } from "./chunk-SQ3KPTIH.js";
93
- import "./chunk-Z4MHKCET.js";
94
- import "./chunk-C4SUTB4O.js";
95
- import {
96
- readUserConfig,
97
- updateUserConfig
98
- } from "./chunk-NXZLDPHZ.js";
99
- import "./chunk-II7O6SCF.js";
100
68
  import {
101
69
  getTestOverrides
102
70
  } from "./chunk-RL7RA2JG.js";
@@ -104,7 +72,7 @@ import {
104
72
  pathExists,
105
73
  readJson,
106
74
  writeJson
107
- } from "./chunk-NUKGEVK2.js";
75
+ } from "./chunk-763CNX5X.js";
108
76
  import {
109
77
  external_exports
110
78
  } from "./chunk-F43XHKVL.js";
@@ -112,7 +80,7 @@ import {
112
80
  CliError,
113
81
  CliErrorCode,
114
82
  require_lib
115
- } from "./chunk-TEHIT3JS.js";
83
+ } from "./chunk-CU77QH5G.js";
116
84
  import {
117
85
  __commonJS,
118
86
  __dirname,
@@ -3033,9 +3001,9 @@ ${trace}`);
3033
3001
  function isMemberExpressionLike(node) {
3034
3002
  return (0, _index.isMemberExpression)(node) || (0, _index.isMetaProperty)(node);
3035
3003
  }
3036
- function matchesPattern(member, match12, allowPartial) {
3004
+ function matchesPattern(member, match9, allowPartial) {
3037
3005
  if (!isMemberExpressionLike(member)) return false;
3038
- const parts = Array.isArray(match12) ? match12 : match12.split(".");
3006
+ const parts = Array.isArray(match9) ? match9 : match9.split(".");
3039
3007
  const nodes = [];
3040
3008
  let node;
3041
3009
  for (node = member; isMemberExpressionLike(node); node = (_object = node.object) != null ? _object : node.meta) {
@@ -3075,8 +3043,8 @@ ${trace}`);
3075
3043
  });
3076
3044
  exports2.default = buildMatchMemberExpression;
3077
3045
  var _matchesPattern = require_matchesPattern();
3078
- function buildMatchMemberExpression(match12, allowPartial) {
3079
- const parts = match12.split(".");
3046
+ function buildMatchMemberExpression(match9, allowPartial) {
3047
+ const parts = match9.split(".");
3080
3048
  return (member) => (0, _matchesPattern.default)(member, parts, allowPartial);
3081
3049
  }
3082
3050
  }
@@ -3111,9 +3079,9 @@ ${trace}`);
3111
3079
  Object.defineProperty(exports2, "__esModule", {
3112
3080
  value: true
3113
3081
  });
3114
- exports2.default = isType4;
3082
+ exports2.default = isType3;
3115
3083
  var _index = require_definitions();
3116
- function isType4(nodeType, targetType) {
3084
+ function isType3(nodeType, targetType) {
3117
3085
  if (nodeType === targetType) return true;
3118
3086
  if (nodeType == null) return false;
3119
3087
  if (_index.ALIAS_KEYS[targetType]) return false;
@@ -3506,8 +3474,8 @@ ${trace}`);
3506
3474
  default:
3507
3475
  if (ch >= 48 && ch <= 55) {
3508
3476
  const startPos = pos2 - 1;
3509
- const match12 = /^[0-7]+/.exec(input.slice(startPos, pos2 + 2));
3510
- let octalStr = match12[0];
3477
+ const match9 = /^[0-7]+/.exec(input.slice(startPos, pos2 + 2));
3478
+ let octalStr = match9[0];
3511
3479
  let octal = parseInt(octalStr, 8);
3512
3480
  if (octal > 255) {
3513
3481
  octalStr = octalStr.slice(0, -1);
@@ -3909,9 +3877,9 @@ ${errors.join("\n")}`);
3909
3877
  }
3910
3878
  function defineType(type, opts = {}) {
3911
3879
  const inherits = opts.inherits && store[opts.inherits] || {};
3912
- let fields4 = opts.fields;
3913
- if (!fields4) {
3914
- fields4 = {};
3880
+ let fields3 = opts.fields;
3881
+ if (!fields3) {
3882
+ fields3 = {};
3915
3883
  if (inherits.fields) {
3916
3884
  const keys = Object.getOwnPropertyNames(inherits.fields);
3917
3885
  for (const key2 of keys) {
@@ -3920,7 +3888,7 @@ ${errors.join("\n")}`);
3920
3888
  if (Array.isArray(def) ? def.length > 0 : def && typeof def === "object") {
3921
3889
  throw new Error("field defaults can only be primitives or empty arrays currently");
3922
3890
  }
3923
- fields4[key2] = {
3891
+ fields3[key2] = {
3924
3892
  default: Array.isArray(def) ? [] : def,
3925
3893
  optional: field.optional,
3926
3894
  deprecated: field.deprecated,
@@ -3941,10 +3909,10 @@ ${errors.join("\n")}`);
3941
3909
  DEPRECATED_KEYS[opts.deprecatedAlias] = type;
3942
3910
  }
3943
3911
  for (const key2 of visitor.concat(builder)) {
3944
- fields4[key2] = fields4[key2] || {};
3912
+ fields3[key2] = fields3[key2] || {};
3945
3913
  }
3946
- for (const key2 of Object.keys(fields4)) {
3947
- const field = fields4[key2];
3914
+ for (const key2 of Object.keys(fields3)) {
3915
+ const field = fields3[key2];
3948
3916
  if (field.default !== void 0 && !builder.includes(key2)) {
3949
3917
  field.optional = true;
3950
3918
  }
@@ -3961,7 +3929,7 @@ ${errors.join("\n")}`);
3961
3929
  }
3962
3930
  VISITOR_KEYS[type] = opts.visitor = visitor;
3963
3931
  BUILDER_KEYS[type] = opts.builder = builder;
3964
- NODE_FIELDS[type] = opts.fields = fields4;
3932
+ NODE_FIELDS[type] = opts.fields = fields3;
3965
3933
  ALIAS_KEYS[type] = opts.aliases = aliases;
3966
3934
  aliases.forEach((alias) => {
3967
3935
  FLIPPED_ALIAS_KEYS[alias] = FLIPPED_ALIAS_KEYS[alias] || [];
@@ -4348,9 +4316,9 @@ ${errors.join("\n")}`);
4348
4316
  }
4349
4317
  }),
4350
4318
  validate: process.env.BABEL_TYPES_8_BREAKING ? function(parent, key2, node) {
4351
- const match12 = /\.(\w+)$/.exec(key2.toString());
4352
- if (!match12) return;
4353
- const [, parentKey] = match12;
4319
+ const match9 = /\.(\w+)$/.exec(key2.toString());
4320
+ if (!match9) return;
4321
+ const [, parentKey] = match9;
4354
4322
  const nonComp = {
4355
4323
  computed: false
4356
4324
  };
@@ -4638,9 +4606,9 @@ ${errors.join("\n")}`);
4638
4606
  }
4639
4607
  }),
4640
4608
  validate: process.env.BABEL_TYPES_8_BREAKING ? function(parent, key2) {
4641
- const match12 = /(\w+)\[(\d+)\]/.exec(key2.toString());
4642
- if (!match12) throw new Error("Internal Babel error: malformed key.");
4643
- const [, listKey, index] = match12;
4609
+ const match9 = /(\w+)\[(\d+)\]/.exec(key2.toString());
4610
+ if (!match9) throw new Error("Internal Babel error: malformed key.");
4611
+ const [, listKey, index] = match9;
4644
4612
  if (parent[listKey].length > +index + 1) {
4645
4613
  throw new TypeError(`RestElement must be last element of ${listKey}`);
4646
4614
  }
@@ -7139,9 +7107,9 @@ Expected ${val.length + 1} quasis but got ${node.quasis.length}`);
7139
7107
  var _index = require_definitions();
7140
7108
  function validate(node, key2, val) {
7141
7109
  if (!node) return;
7142
- const fields4 = _index.NODE_FIELDS[node.type];
7143
- if (!fields4) return;
7144
- const field = fields4[key2];
7110
+ const fields3 = _index.NODE_FIELDS[node.type];
7111
+ if (!fields3) return;
7112
+ const field = fields3[key2];
7145
7113
  validateField(node, key2, val, field);
7146
7114
  validateChild(node, key2, val);
7147
7115
  }
@@ -12347,7 +12315,7 @@ Expected ${val.length + 1} quasis but got ${node.quasis.length}`);
12347
12315
  name += (0, _helperValidatorIdentifier.isIdentifierChar)(c2.codePointAt(0)) ? c2 : "-";
12348
12316
  }
12349
12317
  name = name.replace(/^[-0-9]+/, "");
12350
- name = name.replace(/[-\s]+(.)?/g, function(match12, c2) {
12318
+ name = name.replace(/[-\s]+(.)?/g, function(match9, c2) {
12351
12319
  return c2 ? c2.toUpperCase() : "";
12352
12320
  });
12353
12321
  if (!(0, _isValidIdentifier.default)(name)) {
@@ -13108,9 +13076,9 @@ Expected ${val.length + 1} quasis but got ${node.quasis.length}`);
13108
13076
  if (a.type !== b.type) {
13109
13077
  return false;
13110
13078
  }
13111
- const fields4 = Object.keys(_index.NODE_FIELDS[a.type] || a.type);
13079
+ const fields3 = Object.keys(_index.NODE_FIELDS[a.type] || a.type);
13112
13080
  const visitorKeys = _index.VISITOR_KEYS[a.type];
13113
- for (const field of fields4) {
13081
+ for (const field of fields3) {
13114
13082
  const val_a = a[field];
13115
13083
  const val_b = b[field];
13116
13084
  if (typeof val_a !== typeof val_b) {
@@ -19655,8 +19623,8 @@ ${str}
19655
19623
  default:
19656
19624
  if (ch >= 48 && ch <= 55) {
19657
19625
  const startPos = pos2 - 1;
19658
- const match12 = /^[0-7]+/.exec(input.slice(startPos, pos2 + 2));
19659
- let octalStr = match12[0];
19626
+ const match9 = /^[0-7]+/.exec(input.slice(startPos, pos2 + 2));
19627
+ let octalStr = match9[0];
19660
19628
  let octal = parseInt(octalStr, 8);
19661
19629
  if (octal > 255) {
19662
19630
  octalStr = octalStr.slice(0, -1);
@@ -28787,16 +28755,16 @@ ${str}
28787
28755
  value: true
28788
28756
  });
28789
28757
  exports2.default = /((['"])(?:(?!\2|\\).|\\(?:\r\n|[\s\S]))*(\2)?|`(?:[^`\\$]|\\[\s\S]|\$(?!\{)|\$\{(?:[^{}]|\{[^}]*\}?)*\}?)*(`)?)|(\/\/.*)|(\/\*(?:[^*]|\*(?!\/))*(\*\/)?)|(\/(?!\*)(?:\[(?:(?![\]\\]).|\\.)*\]|(?![\/\]\\]).|\\.)+\/(?:(?!\s*(?:\b|[\u0080-\uFFFF$\\'"~({]|[+\-!](?!=)|\.?\d))|[gmiyus]{1,6}\b(?![\u0080-\uFFFF$\\]|\s*(?:[+\-*%&|^<>!=?({]|\/(?![\/*])))))|(0[xX][\da-fA-F]+|0[oO][0-7]+|0[bB][01]+|(?:\d*\.\d+|\d+\.?)(?:[eE][+-]?\d+)?)|((?!\d)(?:(?!\s)[$\w\u0080-\uFFFF]|\\u[\da-fA-F]{4}|\\u\{[\da-fA-F]+\})+)|(--|\+\+|&&|\|\||=>|\.{3}|(?:[+\-\/%&|^]|\*{1,2}|<{1,2}|>{1,3}|!=?|={1,2})=?|[?~.,:;[\](){}])|(\s+)|(^$|[\s\S])/g;
28790
- exports2.matchToToken = function(match12) {
28791
- var token2 = { type: "invalid", value: match12[0], closed: void 0 };
28792
- if (match12[1]) token2.type = "string", token2.closed = !!(match12[3] || match12[4]);
28793
- else if (match12[5]) token2.type = "comment";
28794
- else if (match12[6]) token2.type = "comment", token2.closed = !!match12[7];
28795
- else if (match12[8]) token2.type = "regex";
28796
- else if (match12[9]) token2.type = "number";
28797
- else if (match12[10]) token2.type = "name";
28798
- else if (match12[11]) token2.type = "punctuator";
28799
- else if (match12[12]) token2.type = "whitespace";
28758
+ exports2.matchToToken = function(match9) {
28759
+ var token2 = { type: "invalid", value: match9[0], closed: void 0 };
28760
+ if (match9[1]) token2.type = "string", token2.closed = !!(match9[3] || match9[4]);
28761
+ else if (match9[5]) token2.type = "comment";
28762
+ else if (match9[6]) token2.type = "comment", token2.closed = !!match9[7];
28763
+ else if (match9[8]) token2.type = "regex";
28764
+ else if (match9[9]) token2.type = "number";
28765
+ else if (match9[10]) token2.type = "name";
28766
+ else if (match9[11]) token2.type = "punctuator";
28767
+ else if (match9[12]) token2.type = "whitespace";
28800
28768
  return token2;
28801
28769
  };
28802
28770
  }
@@ -28861,11 +28829,11 @@ ${str}
28861
28829
  return token2.type;
28862
28830
  };
28863
28831
  tokenize = function* (text) {
28864
- let match12;
28865
- while (match12 = jsTokens.default.exec(text)) {
28866
- const token2 = jsTokens.matchToToken(match12);
28832
+ let match9;
28833
+ while (match9 = jsTokens.default.exec(text)) {
28834
+ const token2 = jsTokens.matchToToken(match9);
28867
28835
  yield {
28868
- type: getTokenType(token2, match12.index, text),
28836
+ type: getTokenType(token2, match9.index, text),
28869
28837
  value: token2.value
28870
28838
  };
28871
28839
  }
@@ -31129,14 +31097,14 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
31129
31097
  if (str.length > 100) {
31130
31098
  return;
31131
31099
  }
31132
- var match12 = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
31100
+ var match9 = /^(-?(?:\d+)?\.?\d+) *(milliseconds?|msecs?|ms|seconds?|secs?|s|minutes?|mins?|m|hours?|hrs?|h|days?|d|weeks?|w|years?|yrs?|y)?$/i.exec(
31133
31101
  str
31134
31102
  );
31135
- if (!match12) {
31103
+ if (!match9) {
31136
31104
  return;
31137
31105
  }
31138
- var n = parseFloat(match12[1]);
31139
- var type = (match12[2] || "ms").toLowerCase();
31106
+ var n = parseFloat(match9[1]);
31107
+ var type = (match9[2] || "ms").toLowerCase();
31140
31108
  switch (type) {
31141
31109
  case "years":
31142
31110
  case "year":
@@ -31266,19 +31234,19 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
31266
31234
  args.unshift("%O");
31267
31235
  }
31268
31236
  let index = 0;
31269
- args[0] = args[0].replace(/%([a-zA-Z%])/g, (match12, format) => {
31270
- if (match12 === "%%") {
31237
+ args[0] = args[0].replace(/%([a-zA-Z%])/g, (match9, format) => {
31238
+ if (match9 === "%%") {
31271
31239
  return "%";
31272
31240
  }
31273
31241
  index++;
31274
31242
  const formatter = createDebug.formatters[format];
31275
31243
  if (typeof formatter === "function") {
31276
31244
  const val = args[index];
31277
- match12 = formatter.call(self2, val);
31245
+ match9 = formatter.call(self2, val);
31278
31246
  args.splice(index, 1);
31279
31247
  index--;
31280
31248
  }
31281
- return match12;
31249
+ return match9;
31282
31250
  });
31283
31251
  createDebug.formatArgs.call(self2, args);
31284
31252
  const logFn = self2.log || createDebug.log;
@@ -31512,12 +31480,12 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
31512
31480
  args.splice(1, 0, c2, "color: inherit");
31513
31481
  let index = 0;
31514
31482
  let lastC = 0;
31515
- args[0].replace(/%[a-zA-Z%]/g, (match12) => {
31516
- if (match12 === "%%") {
31483
+ args[0].replace(/%[a-zA-Z%]/g, (match9) => {
31484
+ if (match9 === "%%") {
31517
31485
  return;
31518
31486
  }
31519
31487
  index++;
31520
- if (match12 === "%c") {
31488
+ if (match9 === "%c") {
31521
31489
  lastC = index;
31522
31490
  }
31523
31491
  });
@@ -33813,8 +33781,8 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
33813
33781
  continue;
33814
33782
  }
33815
33783
  const kind = decodeInteger(reader, 0);
33816
- const fields4 = decodeInteger(reader, 0);
33817
- const hasName = fields4 & 1;
33784
+ const fields3 = decodeInteger(reader, 0);
33785
+ const hasName = fields3 & 1;
33818
33786
  const scope = hasName ? [line2, column2, 0, 0, kind, decodeInteger(reader, 0)] : [line2, column2, 0, 0, kind];
33819
33787
  let vars = EMPTY;
33820
33788
  if (hasMoreVlq(reader, length)) {
@@ -33844,8 +33812,8 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
33844
33812
  state[0] = encodeInteger(writer, startLine, state[0]);
33845
33813
  encodeInteger(writer, startColumn, 0);
33846
33814
  encodeInteger(writer, kind, 0);
33847
- const fields4 = scope.length === 6 ? 1 : 0;
33848
- encodeInteger(writer, fields4, 0);
33815
+ const fields3 = scope.length === 6 ? 1 : 0;
33816
+ encodeInteger(writer, fields3, 0);
33849
33817
  if (scope.length === 6) encodeInteger(writer, scope[5], 0);
33850
33818
  for (const v of vars) {
33851
33819
  encodeInteger(writer, v, 0);
@@ -33887,10 +33855,10 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
33887
33855
  last[3] = genColumn;
33888
33856
  continue;
33889
33857
  }
33890
- const fields4 = decodeInteger(reader, 0);
33891
- const hasDefinition = fields4 & 1;
33892
- const hasCallsite = fields4 & 2;
33893
- const hasScope = fields4 & 4;
33858
+ const fields3 = decodeInteger(reader, 0);
33859
+ const hasDefinition = fields3 & 1;
33860
+ const hasCallsite = fields3 & 2;
33861
+ const hasScope = fields3 & 4;
33894
33862
  let callsite = null;
33895
33863
  let bindings = EMPTY;
33896
33864
  let range;
@@ -33977,8 +33945,8 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
33977
33945
  writer.write(comma);
33978
33946
  }
33979
33947
  state[1] = encodeInteger(writer, range[1], state[1]);
33980
- const fields4 = (range.length === 6 ? 1 : 0) | (callsite ? 2 : 0) | (isScope ? 4 : 0);
33981
- encodeInteger(writer, fields4, 0);
33948
+ const fields3 = (range.length === 6 ? 1 : 0) | (callsite ? 2 : 0) | (isScope ? 4 : 0);
33949
+ encodeInteger(writer, fields3, 0);
33982
33950
  if (range.length === 6) {
33983
33951
  const { 4: sourcesIndex, 5: scopesIndex } = range;
33984
33952
  if (sourcesIndex !== state[2]) {
@@ -34139,13 +34107,13 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
34139
34107
  return /^[.?#]/.test(input);
34140
34108
  }
34141
34109
  function parseAbsoluteUrl(input) {
34142
- const match12 = urlRegex.exec(input);
34143
- return makeUrl(match12[1], match12[2] || "", match12[3], match12[4] || "", match12[5] || "/", match12[6] || "", match12[7] || "");
34110
+ const match9 = urlRegex.exec(input);
34111
+ return makeUrl(match9[1], match9[2] || "", match9[3], match9[4] || "", match9[5] || "/", match9[6] || "", match9[7] || "");
34144
34112
  }
34145
34113
  function parseFileUrl(input) {
34146
- const match12 = fileRegex.exec(input);
34147
- const path = match12[2];
34148
- return makeUrl("file:", "", match12[1] || "", "", isAbsolutePath(path) ? path : "/" + path, match12[3] || "", match12[4] || "");
34114
+ const match9 = fileRegex.exec(input);
34115
+ const path = match9[2];
34116
+ return makeUrl("file:", "", match9[1] || "", "", isAbsolutePath(path) ? path : "/" + path, match9[3] || "", match9[4] || "");
34149
34117
  }
34150
34118
  function makeUrl(scheme, user, host, port, path, query, hash) {
34151
34119
  return {
@@ -35658,7 +35626,7 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
35658
35626
  return false;
35659
35627
  }
35660
35628
  }
35661
- function isType4(node) {
35629
+ function isType3(node) {
35662
35630
  return isLiteral(node) || isObjectExpression(node) || isArrayExpression(node) || isIdentifier(node) || isMemberExpression(node);
35663
35631
  }
35664
35632
  var nodes = exports2.nodes = {
@@ -35694,7 +35662,7 @@ var e,t,r="function"==typeof Symbol?Symbol:{},n=r.iterator||"@@iterator",o=r.toS
35694
35662
  VariableDeclaration(node) {
35695
35663
  for (let i = 0; i < node.declarations.length; i++) {
35696
35664
  const declar = node.declarations[i];
35697
- let enabled = isHelper(declar.id) && !isType4(declar.init);
35665
+ let enabled = isHelper(declar.id) && !isType3(declar.init);
35698
35666
  if (!enabled && declar.init) {
35699
35667
  const state = crawl(declar.init);
35700
35668
  enabled = isHelper(declar.init) && state.hasCall || state.hasFunction;
@@ -43275,7 +43243,7 @@ ${" ".repeat(indentSize)}`);
43275
43243
  isIdentifier,
43276
43244
  isLiteral,
43277
43245
  isStringLiteral,
43278
- isType: isType4,
43246
+ isType: isType3,
43279
43247
  matchesPattern: _matchesPattern
43280
43248
  } = _t;
43281
43249
  function matchesPattern(pattern, allowPartial) {
@@ -43305,7 +43273,7 @@ ${" ".repeat(indentSize)}`);
43305
43273
  };
43306
43274
  }
43307
43275
  function isNodeType(type) {
43308
- return isType4(this.type, type);
43276
+ return isType3(this.type, type);
43309
43277
  }
43310
43278
  function canHaveVariableDeclarationOrExpression() {
43311
43279
  return (this.key === "init" || this.key === "left") && this.parentPath.isFor();
@@ -43561,13 +43529,13 @@ ${" ".repeat(indentSize)}`);
43561
43529
  for (const prop of props) {
43562
43530
  if (!prop.isProperty()) continue;
43563
43531
  const key2 = prop.get("key");
43564
- let match12 = prop.isnt("computed") && key2.isIdentifier({
43532
+ let match9 = prop.isnt("computed") && key2.isIdentifier({
43565
43533
  name: targetName
43566
43534
  });
43567
- match12 = match12 || key2.isLiteral({
43535
+ match9 = match9 || key2.isLiteral({
43568
43536
  value: targetName
43569
43537
  });
43570
- if (match12) return prop.get("value").resolve(dangerous, resolved);
43538
+ if (match9) return prop.get("value").resolve(dangerous, resolved);
43571
43539
  }
43572
43540
  } else if (target.isArrayExpression() && !isNaN(+targetName)) {
43573
43541
  const elems = target.get("elements");
@@ -45155,8 +45123,8 @@ ${" ".repeat(indentSize)}`);
45155
45123
  }
45156
45124
  } while (++i2);
45157
45125
  };
45158
- SemVer.prototype.inc = function(release, identifier) {
45159
- switch (release) {
45126
+ SemVer.prototype.inc = function(release2, identifier) {
45127
+ switch (release2) {
45160
45128
  case "premajor":
45161
45129
  this.prerelease.length = 0;
45162
45130
  this.patch = 0;
@@ -45232,20 +45200,20 @@ ${" ".repeat(indentSize)}`);
45232
45200
  }
45233
45201
  break;
45234
45202
  default:
45235
- throw new Error("invalid increment argument: " + release);
45203
+ throw new Error("invalid increment argument: " + release2);
45236
45204
  }
45237
45205
  this.format();
45238
45206
  this.raw = this.version;
45239
45207
  return this;
45240
45208
  };
45241
45209
  exports2.inc = inc;
45242
- function inc(version, release, loose, identifier) {
45210
+ function inc(version, release2, loose, identifier) {
45243
45211
  if (typeof loose === "string") {
45244
45212
  identifier = loose;
45245
45213
  loose = void 0;
45246
45214
  }
45247
45215
  try {
45248
- return new SemVer(version, loose).inc(release, identifier).version;
45216
+ return new SemVer(version, loose).inc(release2, identifier).version;
45249
45217
  } catch (er) {
45250
45218
  return null;
45251
45219
  }
@@ -45983,23 +45951,23 @@ ${" ".repeat(indentSize)}`);
45983
45951
  return null;
45984
45952
  }
45985
45953
  options = options || {};
45986
- var match12 = null;
45954
+ var match9 = null;
45987
45955
  if (!options.rtl) {
45988
- match12 = version.match(safeRe[t.COERCE]);
45956
+ match9 = version.match(safeRe[t.COERCE]);
45989
45957
  } else {
45990
45958
  var next;
45991
- while ((next = safeRe[t.COERCERTL].exec(version)) && (!match12 || match12.index + match12[0].length !== version.length)) {
45992
- if (!match12 || next.index + next[0].length !== match12.index + match12[0].length) {
45993
- match12 = next;
45959
+ while ((next = safeRe[t.COERCERTL].exec(version)) && (!match9 || match9.index + match9[0].length !== version.length)) {
45960
+ if (!match9 || next.index + next[0].length !== match9.index + match9[0].length) {
45961
+ match9 = next;
45994
45962
  }
45995
45963
  safeRe[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length;
45996
45964
  }
45997
45965
  safeRe[t.COERCERTL].lastIndex = -1;
45998
45966
  }
45999
- if (match12 === null) {
45967
+ if (match9 === null) {
46000
45968
  return null;
46001
45969
  }
46002
- return parse3(match12[2] + "." + (match12[3] || "0") + "." + (match12[4] || "0"), options);
45970
+ return parse3(match9[2] + "." + (match9[3] || "0") + "." + (match9[4] || "0"), options);
46003
45971
  }
46004
45972
  }
46005
45973
  });
@@ -51208,11 +51176,11 @@ ${" ".repeat(indentSize)}`);
51208
51176
  }
51209
51177
  for (var name in all) {
51210
51178
  var type = all[name];
51211
- var match12 = query.match(type.regexp);
51212
- if (match12) {
51179
+ var match9 = query.match(type.regexp);
51180
+ if (match9) {
51213
51181
  node.type = name;
51214
51182
  for (var i = 0; i < type.matches.length; i++) {
51215
- node[type.matches[i]] = match12[i + 1];
51183
+ node[type.matches[i]] = match9[i + 1];
51216
51184
  }
51217
51185
  return node;
51218
51186
  }
@@ -52343,8 +52311,8 @@ ${" ".repeat(indentSize)}`);
52343
52311
  }
52344
52312
  }
52345
52313
  }
52346
- browserslist.nodeVersions = jsReleases.map(function(release) {
52347
- return release.version;
52314
+ browserslist.nodeVersions = jsReleases.map(function(release2) {
52315
+ return release2.version;
52348
52316
  });
52349
52317
  })();
52350
52318
  module2.exports = browserslist;
@@ -53410,8 +53378,8 @@ ${" ".repeat(indentSize)}`);
53410
53378
  }
53411
53379
  } while (++i2);
53412
53380
  };
53413
- SemVer.prototype.inc = function(release, identifier) {
53414
- switch (release) {
53381
+ SemVer.prototype.inc = function(release2, identifier) {
53382
+ switch (release2) {
53415
53383
  case "premajor":
53416
53384
  this.prerelease.length = 0;
53417
53385
  this.patch = 0;
@@ -53487,20 +53455,20 @@ ${" ".repeat(indentSize)}`);
53487
53455
  }
53488
53456
  break;
53489
53457
  default:
53490
- throw new Error("invalid increment argument: " + release);
53458
+ throw new Error("invalid increment argument: " + release2);
53491
53459
  }
53492
53460
  this.format();
53493
53461
  this.raw = this.version;
53494
53462
  return this;
53495
53463
  };
53496
53464
  exports2.inc = inc;
53497
- function inc(version, release, loose, identifier) {
53465
+ function inc(version, release2, loose, identifier) {
53498
53466
  if (typeof loose === "string") {
53499
53467
  identifier = loose;
53500
53468
  loose = void 0;
53501
53469
  }
53502
53470
  try {
53503
- return new SemVer(version, loose).inc(release, identifier).version;
53471
+ return new SemVer(version, loose).inc(release2, identifier).version;
53504
53472
  } catch (er) {
53505
53473
  return null;
53506
53474
  }
@@ -54238,23 +54206,23 @@ ${" ".repeat(indentSize)}`);
54238
54206
  return null;
54239
54207
  }
54240
54208
  options = options || {};
54241
- var match12 = null;
54209
+ var match9 = null;
54242
54210
  if (!options.rtl) {
54243
- match12 = version.match(safeRe[t.COERCE]);
54211
+ match9 = version.match(safeRe[t.COERCE]);
54244
54212
  } else {
54245
54213
  var next;
54246
- while ((next = safeRe[t.COERCERTL].exec(version)) && (!match12 || match12.index + match12[0].length !== version.length)) {
54247
- if (!match12 || next.index + next[0].length !== match12.index + match12[0].length) {
54248
- match12 = next;
54214
+ while ((next = safeRe[t.COERCERTL].exec(version)) && (!match9 || match9.index + match9[0].length !== version.length)) {
54215
+ if (!match9 || next.index + next[0].length !== match9.index + match9[0].length) {
54216
+ match9 = next;
54249
54217
  }
54250
54218
  safeRe[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length;
54251
54219
  }
54252
54220
  safeRe[t.COERCERTL].lastIndex = -1;
54253
54221
  }
54254
- if (match12 === null) {
54222
+ if (match9 === null) {
54255
54223
  return null;
54256
54224
  }
54257
- return parse3(match12[2] + "." + (match12[3] || "0") + "." + (match12[4] || "0"), options);
54225
+ return parse3(match9[2] + "." + (match9[3] || "0") + "." + (match9[4] || "0"), options);
54258
54226
  }
54259
54227
  }
54260
54228
  });
@@ -58701,8 +58669,8 @@ See https://babeljs.io/docs/configuration#print-effective-configs for more info.
58701
58669
  const lastComment = extractComments(EXTERNAL_SOURCEMAP_REGEX, ast);
58702
58670
  if (typeof options.filename === "string" && lastComment) {
58703
58671
  try {
58704
- const match12 = EXTERNAL_SOURCEMAP_REGEX.exec(lastComment);
58705
- const inputMapContent = _fs().readFileSync(_path().resolve(_path().dirname(options.filename), match12[1]), "utf8");
58672
+ const match9 = EXTERNAL_SOURCEMAP_REGEX.exec(lastComment);
58673
+ const inputMapContent = _fs().readFileSync(_path().resolve(_path().dirname(options.filename), match9[1]), "utf8");
58706
58674
  inputMap = _convertSourceMap().fromJSON(inputMapContent);
58707
58675
  } catch (err) {
58708
58676
  debug("discarding unknown file input sourcemap", err);
@@ -63006,8 +62974,8 @@ If you have already enabled that plugin (or '@babel/preset-typescript'), make su
63006
62974
  }
63007
62975
  } while (++i2);
63008
62976
  };
63009
- SemVer.prototype.inc = function(release, identifier) {
63010
- switch (release) {
62977
+ SemVer.prototype.inc = function(release2, identifier) {
62978
+ switch (release2) {
63011
62979
  case "premajor":
63012
62980
  this.prerelease.length = 0;
63013
62981
  this.patch = 0;
@@ -63083,20 +63051,20 @@ If you have already enabled that plugin (or '@babel/preset-typescript'), make su
63083
63051
  }
63084
63052
  break;
63085
63053
  default:
63086
- throw new Error("invalid increment argument: " + release);
63054
+ throw new Error("invalid increment argument: " + release2);
63087
63055
  }
63088
63056
  this.format();
63089
63057
  this.raw = this.version;
63090
63058
  return this;
63091
63059
  };
63092
63060
  exports2.inc = inc;
63093
- function inc(version, release, loose, identifier) {
63061
+ function inc(version, release2, loose, identifier) {
63094
63062
  if (typeof loose === "string") {
63095
63063
  identifier = loose;
63096
63064
  loose = void 0;
63097
63065
  }
63098
63066
  try {
63099
- return new SemVer(version, loose).inc(release, identifier).version;
63067
+ return new SemVer(version, loose).inc(release2, identifier).version;
63100
63068
  } catch (er) {
63101
63069
  return null;
63102
63070
  }
@@ -63834,23 +63802,23 @@ If you have already enabled that plugin (or '@babel/preset-typescript'), make su
63834
63802
  return null;
63835
63803
  }
63836
63804
  options = options || {};
63837
- var match12 = null;
63805
+ var match9 = null;
63838
63806
  if (!options.rtl) {
63839
- match12 = version.match(safeRe[t.COERCE]);
63807
+ match9 = version.match(safeRe[t.COERCE]);
63840
63808
  } else {
63841
63809
  var next;
63842
- while ((next = safeRe[t.COERCERTL].exec(version)) && (!match12 || match12.index + match12[0].length !== version.length)) {
63843
- if (!match12 || next.index + next[0].length !== match12.index + match12[0].length) {
63844
- match12 = next;
63810
+ while ((next = safeRe[t.COERCERTL].exec(version)) && (!match9 || match9.index + match9[0].length !== version.length)) {
63811
+ if (!match9 || next.index + next[0].length !== match9.index + match9[0].length) {
63812
+ match9 = next;
63845
63813
  }
63846
63814
  safeRe[t.COERCERTL].lastIndex = next.index + next[1].length + next[2].length;
63847
63815
  }
63848
63816
  safeRe[t.COERCERTL].lastIndex = -1;
63849
63817
  }
63850
- if (match12 === null) {
63818
+ if (match9 === null) {
63851
63819
  return null;
63852
63820
  }
63853
- return parse3(match12[2] + "." + (match12[3] || "0") + "." + (match12[4] || "0"), options);
63821
+ return parse3(match9[2] + "." + (match9[3] || "0") + "." + (match9[4] || "0"), options);
63854
63822
  }
63855
63823
  }
63856
63824
  });
@@ -66620,13 +66588,13 @@ module.exports = function(api) {
66620
66588
  var encodedSeparatorRegEx = /%2f|%5c/i;
66621
66589
  var emittedPackageWarnings = /* @__PURE__ */ new Set();
66622
66590
  var doubleSlashRegEx = /[/\\]{2}/;
66623
- function emitInvalidSegmentDeprecation(target, request, match12, packageJsonUrl, internal, base, isTarget) {
66591
+ function emitInvalidSegmentDeprecation(target, request, match9, packageJsonUrl, internal, base, isTarget) {
66624
66592
  if (_process().noDeprecation) {
66625
66593
  return;
66626
66594
  }
66627
66595
  const pjsonPath = (0, _url().fileURLToPath)(packageJsonUrl);
66628
66596
  const double = doubleSlashRegEx.exec(isTarget ? target : request) !== null;
66629
- _process().emitWarning(`Use of deprecated ${double ? "double slash" : "leading or trailing slash matching"} resolving "${target}" for module request "${request}" ${request === match12 ? "" : `matched to "${match12}" `}in the "${internal ? "imports" : "exports"}" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${(0, _url().fileURLToPath)(base)}` : ""}.`, "DeprecationWarning", "DEP0166");
66597
+ _process().emitWarning(`Use of deprecated ${double ? "double slash" : "leading or trailing slash matching"} resolving "${target}" for module request "${request}" ${request === match9 ? "" : `matched to "${match9}" `}in the "${internal ? "imports" : "exports"}" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${(0, _url().fileURLToPath)(base)}` : ""}.`, "DeprecationWarning", "DEP0166");
66630
66598
  }
66631
66599
  function emitLegacyIndexDeprecation(url, packageJsonUrl, base, main) {
66632
66600
  if (_process().noDeprecation) {
@@ -66736,16 +66704,16 @@ Default "index" lookups for the main are deprecated for ES modules.`, "Deprecati
66736
66704
  function exportsNotFound(subpath, packageJsonUrl, base) {
66737
66705
  return new ERR_PACKAGE_PATH_NOT_EXPORTED((0, _url().fileURLToPath)(new (_url()).URL(".", packageJsonUrl)), subpath, base && (0, _url().fileURLToPath)(base));
66738
66706
  }
66739
- function throwInvalidSubpath(request, match12, packageJsonUrl, internal, base) {
66740
- const reason = `request is not a valid match in pattern "${match12}" for the "${internal ? "imports" : "exports"}" resolution of ${(0, _url().fileURLToPath)(packageJsonUrl)}`;
66707
+ function throwInvalidSubpath(request, match9, packageJsonUrl, internal, base) {
66708
+ const reason = `request is not a valid match in pattern "${match9}" for the "${internal ? "imports" : "exports"}" resolution of ${(0, _url().fileURLToPath)(packageJsonUrl)}`;
66741
66709
  throw new ERR_INVALID_MODULE_SPECIFIER(request, reason, base && (0, _url().fileURLToPath)(base));
66742
66710
  }
66743
66711
  function invalidPackageTarget(subpath, target, packageJsonUrl, internal, base) {
66744
66712
  target = typeof target === "object" && target !== null ? JSON.stringify(target, null, "") : `${target}`;
66745
66713
  return new ERR_INVALID_PACKAGE_TARGET((0, _url().fileURLToPath)(new (_url()).URL(".", packageJsonUrl)), subpath, target, internal, base && (0, _url().fileURLToPath)(base));
66746
66714
  }
66747
- function resolvePackageTargetString(target, subpath, match12, packageJsonUrl, base, pattern, internal, isPathMap, conditions) {
66748
- if (subpath !== "" && !pattern && target[target.length - 1] !== "/") throw invalidPackageTarget(match12, target, packageJsonUrl, internal, base);
66715
+ function resolvePackageTargetString(target, subpath, match9, packageJsonUrl, base, pattern, internal, isPathMap, conditions) {
66716
+ if (subpath !== "" && !pattern && target[target.length - 1] !== "/") throw invalidPackageTarget(match9, target, packageJsonUrl, internal, base);
66749
66717
  if (!target.startsWith("./")) {
66750
66718
  if (internal && !target.startsWith("../") && !target.startsWith("/")) {
66751
66719
  let isURL2 = false;
@@ -66759,33 +66727,33 @@ Default "index" lookups for the main are deprecated for ES modules.`, "Deprecati
66759
66727
  return packageResolve(exportTarget, packageJsonUrl, conditions);
66760
66728
  }
66761
66729
  }
66762
- throw invalidPackageTarget(match12, target, packageJsonUrl, internal, base);
66730
+ throw invalidPackageTarget(match9, target, packageJsonUrl, internal, base);
66763
66731
  }
66764
66732
  if (invalidSegmentRegEx.exec(target.slice(2)) !== null) {
66765
66733
  if (deprecatedInvalidSegmentRegEx.exec(target.slice(2)) === null) {
66766
66734
  if (!isPathMap) {
66767
- const request = pattern ? match12.replace("*", () => subpath) : match12 + subpath;
66735
+ const request = pattern ? match9.replace("*", () => subpath) : match9 + subpath;
66768
66736
  const resolvedTarget = pattern ? RegExpPrototypeSymbolReplace.call(patternRegEx, target, () => subpath) : target;
66769
- emitInvalidSegmentDeprecation(resolvedTarget, request, match12, packageJsonUrl, internal, base, true);
66737
+ emitInvalidSegmentDeprecation(resolvedTarget, request, match9, packageJsonUrl, internal, base, true);
66770
66738
  }
66771
66739
  } else {
66772
- throw invalidPackageTarget(match12, target, packageJsonUrl, internal, base);
66740
+ throw invalidPackageTarget(match9, target, packageJsonUrl, internal, base);
66773
66741
  }
66774
66742
  }
66775
66743
  const resolved = new (_url()).URL(target, packageJsonUrl);
66776
66744
  const resolvedPath = resolved.pathname;
66777
66745
  const packagePath = new (_url()).URL(".", packageJsonUrl).pathname;
66778
- if (!resolvedPath.startsWith(packagePath)) throw invalidPackageTarget(match12, target, packageJsonUrl, internal, base);
66746
+ if (!resolvedPath.startsWith(packagePath)) throw invalidPackageTarget(match9, target, packageJsonUrl, internal, base);
66779
66747
  if (subpath === "") return resolved;
66780
66748
  if (invalidSegmentRegEx.exec(subpath) !== null) {
66781
- const request = pattern ? match12.replace("*", () => subpath) : match12 + subpath;
66749
+ const request = pattern ? match9.replace("*", () => subpath) : match9 + subpath;
66782
66750
  if (deprecatedInvalidSegmentRegEx.exec(subpath) === null) {
66783
66751
  if (!isPathMap) {
66784
66752
  const resolvedTarget = pattern ? RegExpPrototypeSymbolReplace.call(patternRegEx, target, () => subpath) : target;
66785
- emitInvalidSegmentDeprecation(resolvedTarget, request, match12, packageJsonUrl, internal, base, false);
66753
+ emitInvalidSegmentDeprecation(resolvedTarget, request, match9, packageJsonUrl, internal, base, false);
66786
66754
  }
66787
66755
  } else {
66788
- throwInvalidSubpath(request, match12, packageJsonUrl, internal, base);
66756
+ throwInvalidSubpath(request, match9, packageJsonUrl, internal, base);
66789
66757
  }
66790
66758
  }
66791
66759
  if (pattern) {
@@ -66874,14 +66842,14 @@ Default "index" lookups for the main are deprecated for ES modules.`, "Deprecati
66874
66842
  }
66875
66843
  return isConditionalSugar;
66876
66844
  }
66877
- function emitTrailingSlashPatternDeprecation(match12, pjsonUrl, base) {
66845
+ function emitTrailingSlashPatternDeprecation(match9, pjsonUrl, base) {
66878
66846
  if (_process().noDeprecation) {
66879
66847
  return;
66880
66848
  }
66881
66849
  const pjsonPath = (0, _url().fileURLToPath)(pjsonUrl);
66882
- if (emittedPackageWarnings.has(pjsonPath + "|" + match12)) return;
66883
- emittedPackageWarnings.add(pjsonPath + "|" + match12);
66884
- _process().emitWarning(`Use of deprecated trailing slash pattern mapping "${match12}" in the "exports" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${(0, _url().fileURLToPath)(base)}` : ""}. Mapping specifiers ending in "/" is no longer supported.`, "DeprecationWarning", "DEP0155");
66850
+ if (emittedPackageWarnings.has(pjsonPath + "|" + match9)) return;
66851
+ emittedPackageWarnings.add(pjsonPath + "|" + match9);
66852
+ _process().emitWarning(`Use of deprecated trailing slash pattern mapping "${match9}" in the "exports" field module resolution of the package at ${pjsonPath}${base ? ` imported from ${(0, _url().fileURLToPath)(base)}` : ""}. Mapping specifiers ending in "/" is no longer supported.`, "DeprecationWarning", "DEP0155");
66885
66853
  }
66886
66854
  function packageExportsResolve(packageJsonUrl, packageSubpath, packageConfig, base, conditions) {
66887
66855
  let exports3 = packageConfig.exports;
@@ -68679,8 +68647,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68679
68647
  * @returns {Promise} A promise that resolves when the release has been created.
68680
68648
  * @memberof SentryReleases
68681
68649
  */
68682
- async new(release, options) {
68683
- const args = ["releases", "new", release].concat(helper.getProjectFlagsFromOptions(options));
68650
+ async new(release2, options) {
68651
+ const args = ["releases", "new", release2].concat(helper.getProjectFlagsFromOptions(options));
68684
68652
  return this.execute(args, null);
68685
68653
  }
68686
68654
  /**
@@ -68704,7 +68672,7 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68704
68672
  * @returns {Promise} A promise that resolves when the commits have been associated
68705
68673
  * @memberof SentryReleases
68706
68674
  */
68707
- async setCommits(release, options) {
68675
+ async setCommits(release2, options) {
68708
68676
  if (!options || !options.auto && (!options.repo || !options.commit)) {
68709
68677
  throw new Error("options.auto, or options.repo and options.commit must be specified");
68710
68678
  }
@@ -68719,7 +68687,7 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68719
68687
  if (options.ignoreMissing) {
68720
68688
  commitFlags.push("--ignore-missing");
68721
68689
  }
68722
- return this.execute(["releases", "set-commits", release].concat(commitFlags), false);
68690
+ return this.execute(["releases", "set-commits", release2].concat(commitFlags), false);
68723
68691
  }
68724
68692
  /**
68725
68693
  * Marks this release as complete. This should be called once all artifacts has been
@@ -68729,8 +68697,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68729
68697
  * @returns {Promise} A promise that resolves when the release has been finalized.
68730
68698
  * @memberof SentryReleases
68731
68699
  */
68732
- async finalize(release) {
68733
- return this.execute(["releases", "finalize", release], null);
68700
+ async finalize(release2) {
68701
+ return this.execute(["releases", "finalize", release2], null);
68734
68702
  }
68735
68703
  /**
68736
68704
  * Creates a unique, deterministic version identifier based on the project type and
@@ -68778,7 +68746,7 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68778
68746
  * @returns {Promise} A promise that resolves when the upload has completed successfully.
68779
68747
  * @memberof SentryReleases
68780
68748
  */
68781
- async uploadSourceMaps(release, options) {
68749
+ async uploadSourceMaps(release2, options) {
68782
68750
  if (!options || !options.include || !Array.isArray(options.include)) {
68783
68751
  throw new Error(
68784
68752
  "`options.include` must be a valid array of paths and/or path descriptor objects."
@@ -68803,7 +68771,7 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68803
68771
  if (!newOptions.ignoreFile && !newOptions.ignore) {
68804
68772
  newOptions.ignore = DEFAULT_IGNORE;
68805
68773
  }
68806
- const args = ["sourcemaps", "upload"].concat(helper.getProjectFlagsFromOptions(options)).concat(["--release", release]);
68774
+ const args = ["sourcemaps", "upload"].concat(helper.getProjectFlagsFromOptions(options)).concat(["--release", release2]);
68807
68775
  return uploadPaths.map(
68808
68776
  (path) => (
68809
68777
  // `execute()` is async and thus we're returning a promise here
@@ -68823,8 +68791,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68823
68791
  * @returns {Promise} A promise that resolves when the list comes back from the server.
68824
68792
  * @memberof SentryReleases
68825
68793
  */
68826
- async listDeploys(release) {
68827
- return this.execute(["releases", "deploys", release, "list"], null);
68794
+ async listDeploys(release2) {
68795
+ return this.execute(["releases", "deploys", release2, "list"], null);
68828
68796
  }
68829
68797
  /**
68830
68798
  * Creates a new release deployment. This should be called after the release has been
@@ -68848,11 +68816,11 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
68848
68816
  * @returns {Promise} A promise that resolves when the deploy has been created.
68849
68817
  * @memberof SentryReleases
68850
68818
  */
68851
- async newDeploy(release, options) {
68819
+ async newDeploy(release2, options) {
68852
68820
  if (!options || !options.env) {
68853
68821
  throw new Error("options.env must be a valid name");
68854
68822
  }
68855
- const args = ["releases", "deploys", release, "new"];
68823
+ const args = ["releases", "deploys", release2, "new"];
68856
68824
  return this.execute(helper.prepareCommand(args, DEPLOYS_SCHEMA, options), null);
68857
68825
  }
68858
68826
  /**
@@ -69897,7 +69865,7 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
69897
69865
  var makeRe = (pattern, options = {}) => new Minimatch(pattern, options).makeRe();
69898
69866
  exports2.makeRe = makeRe;
69899
69867
  exports2.minimatch.makeRe = exports2.makeRe;
69900
- var match12 = (list, pattern, options = {}) => {
69868
+ var match9 = (list, pattern, options = {}) => {
69901
69869
  const mm = new Minimatch(pattern, options);
69902
69870
  list = list.filter((f) => mm.match(f));
69903
69871
  if (mm.options.nonull && !list.length) {
@@ -69905,7 +69873,7 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
69905
69873
  }
69906
69874
  return list;
69907
69875
  };
69908
- exports2.match = match12;
69876
+ exports2.match = match9;
69909
69877
  exports2.minimatch.match = exports2.match;
69910
69878
  var globMagic = /[?*]|[+@!]\(.*?\)|\[|\]/;
69911
69879
  var regExpEscape = (s) => s.replace(/[-[\]{}()*+?.,\\^$|#\s]/g, "\\$&");
@@ -76689,10 +76657,10 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
76689
76657
  });
76690
76658
  }
76691
76659
  let shouldIndentNextCharacter = options.indentStart !== false;
76692
- const replacer = (match12) => {
76693
- if (shouldIndentNextCharacter) return `${indentStr}${match12}`;
76660
+ const replacer = (match9) => {
76661
+ if (shouldIndentNextCharacter) return `${indentStr}${match9}`;
76694
76662
  shouldIndentNextCharacter = true;
76695
- return match12;
76663
+ return match9;
76696
76664
  };
76697
76665
  this.intro = this.intro.replace(pattern, replacer);
76698
76666
  let charIndex = 0;
@@ -77080,44 +77048,44 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
77080
77048
  return this.original !== this.toString();
77081
77049
  }
77082
77050
  _replaceRegexp(searchValue, replacement) {
77083
- function getReplacement(match12, str) {
77051
+ function getReplacement(match9, str) {
77084
77052
  if (typeof replacement === "string") {
77085
77053
  return replacement.replace(/\$(\$|&|\d+)/g, (_, i) => {
77086
77054
  if (i === "$") return "$";
77087
- if (i === "&") return match12[0];
77055
+ if (i === "&") return match9[0];
77088
77056
  const num = +i;
77089
- if (num < match12.length) return match12[+i];
77057
+ if (num < match9.length) return match9[+i];
77090
77058
  return `$${i}`;
77091
77059
  });
77092
77060
  } else {
77093
- return replacement(...match12, match12.index, str, match12.groups);
77061
+ return replacement(...match9, match9.index, str, match9.groups);
77094
77062
  }
77095
77063
  }
77096
77064
  function matchAll(re, str) {
77097
- let match12;
77065
+ let match9;
77098
77066
  const matches = [];
77099
- while (match12 = re.exec(str)) {
77100
- matches.push(match12);
77067
+ while (match9 = re.exec(str)) {
77068
+ matches.push(match9);
77101
77069
  }
77102
77070
  return matches;
77103
77071
  }
77104
77072
  if (searchValue.global) {
77105
77073
  const matches = matchAll(searchValue, this.original);
77106
- matches.forEach((match12) => {
77107
- if (match12.index != null)
77074
+ matches.forEach((match9) => {
77075
+ if (match9.index != null)
77108
77076
  this.overwrite(
77109
- match12.index,
77110
- match12.index + match12[0].length,
77111
- getReplacement(match12, this.original)
77077
+ match9.index,
77078
+ match9.index + match9[0].length,
77079
+ getReplacement(match9, this.original)
77112
77080
  );
77113
77081
  });
77114
77082
  } else {
77115
- const match12 = this.original.match(searchValue);
77116
- if (match12 && match12.index != null)
77083
+ const match9 = this.original.match(searchValue);
77084
+ if (match9 && match9.index != null)
77117
77085
  this.overwrite(
77118
- match12.index,
77119
- match12.index + match12[0].length,
77120
- getReplacement(match12, this.original)
77086
+ match9.index,
77087
+ match9.index + match9[0].length,
77088
+ getReplacement(match9, this.original)
77121
77089
  );
77122
77090
  }
77123
77091
  return this;
@@ -77321,8 +77289,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
77321
77289
  trailingNewline = source2.content.lastChar() === "\n";
77322
77290
  });
77323
77291
  if (this.intro) {
77324
- this.intro = indentStr + this.intro.replace(/^[^\n]/gm, (match12, index) => {
77325
- return index > 0 ? indentStr + match12 : match12;
77292
+ this.intro = indentStr + this.intro.replace(/^[^\n]/gm, (match9, index) => {
77293
+ return index > 0 ? indentStr + match9 : match9;
77326
77294
  });
77327
77295
  }
77328
77296
  return this;
@@ -77603,8 +77571,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
77603
77571
  exports2.escapeRegex = (str) => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, "\\$1");
77604
77572
  exports2.toPosixSlashes = (str) => str.replace(REGEX_BACKSLASH, "/");
77605
77573
  exports2.removeBackslashes = (str) => {
77606
- return str.replace(REGEX_REMOVE_BACKSLASH, (match12) => {
77607
- return match12 === "\\" ? "" : match12;
77574
+ return str.replace(REGEX_REMOVE_BACKSLASH, (match9) => {
77575
+ return match9 === "\\" ? "" : match9;
77608
77576
  });
77609
77577
  };
77610
77578
  exports2.supportsLookbehinds = () => {
@@ -78221,10 +78189,10 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
78221
78189
  push2({ type: "text", value: value2 });
78222
78190
  continue;
78223
78191
  }
78224
- const match12 = /^\\+/.exec(remaining());
78192
+ const match9 = /^\\+/.exec(remaining());
78225
78193
  let slashes = 0;
78226
- if (match12 && match12[0].length > 2) {
78227
- slashes = match12[0].length;
78194
+ if (match9 && match9[0].length > 2) {
78195
+ slashes = match9[0].length;
78228
78196
  state.index += slashes;
78229
78197
  if (slashes % 2 !== 0) {
78230
78198
  value2 += "\\";
@@ -78512,10 +78480,10 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
78512
78480
  if (value2 === "$" || value2 === "^") {
78513
78481
  value2 = `\\${value2}`;
78514
78482
  }
78515
- const match12 = REGEX_NON_SPECIAL_CHARS.exec(remaining());
78516
- if (match12) {
78517
- value2 += match12[0];
78518
- state.index += match12[0].length;
78483
+ const match9 = REGEX_NON_SPECIAL_CHARS.exec(remaining());
78484
+ if (match9) {
78485
+ value2 += match9[0];
78486
+ state.index += match9[0].length;
78519
78487
  }
78520
78488
  push2({ type: "text", value: value2 });
78521
78489
  continue;
@@ -78726,11 +78694,11 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
78726
78694
  case "**/.*":
78727
78695
  return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`;
78728
78696
  default: {
78729
- const match12 = /^(.*?)\.(\w+)$/.exec(str);
78730
- if (!match12) return;
78731
- const source3 = create(match12[1]);
78697
+ const match9 = /^(.*?)\.(\w+)$/.exec(str);
78698
+ if (!match9) return;
78699
+ const source3 = create(match9[1]);
78732
78700
  if (!source3) return;
78733
- return source3 + DOT_LITERAL + match12[2];
78701
+ return source3 + DOT_LITERAL + match9[2];
78734
78702
  }
78735
78703
  }
78736
78704
  };
@@ -78780,8 +78748,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
78780
78748
  isIgnored = picomatch(opts.ignore, ignoreOpts, returnState);
78781
78749
  }
78782
78750
  const matcher = (input, returnObject = false) => {
78783
- const { isMatch, match: match12, output } = picomatch.test(input, regex, options, { glob, posix });
78784
- const result = { glob, state, regex, posix, input, output, match: match12, isMatch };
78751
+ const { isMatch, match: match9, output } = picomatch.test(input, regex, options, { glob, posix });
78752
+ const result = { glob, state, regex, posix, input, output, match: match9, isMatch };
78785
78753
  if (typeof opts.onResult === "function") {
78786
78754
  opts.onResult(result);
78787
78755
  }
@@ -78815,20 +78783,20 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
78815
78783
  }
78816
78784
  const opts = options || {};
78817
78785
  const format = opts.format || (posix ? utils.toPosixSlashes : null);
78818
- let match12 = input === glob;
78819
- let output = match12 && format ? format(input) : input;
78820
- if (match12 === false) {
78786
+ let match9 = input === glob;
78787
+ let output = match9 && format ? format(input) : input;
78788
+ if (match9 === false) {
78821
78789
  output = format ? format(input) : input;
78822
- match12 = output === glob;
78790
+ match9 = output === glob;
78823
78791
  }
78824
- if (match12 === false || opts.capture === true) {
78792
+ if (match9 === false || opts.capture === true) {
78825
78793
  if (opts.matchBase === true || opts.basename === true) {
78826
- match12 = picomatch.matchBase(input, regex, options, posix);
78794
+ match9 = picomatch.matchBase(input, regex, options, posix);
78827
78795
  } else {
78828
- match12 = regex.exec(output);
78796
+ match9 = regex.exec(output);
78829
78797
  }
78830
78798
  }
78831
- return { isMatch: Boolean(match12), match: match12, output };
78799
+ return { isMatch: Boolean(match9), match: match9, output };
78832
78800
  };
78833
78801
  picomatch.matchBase = (input, glob, options, posix = utils.isWindows(options)) => {
78834
78802
  const regex = glob instanceof RegExp ? glob : picomatch.makeRe(glob, options);
@@ -79329,8 +79297,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
79329
79297
  exports2.escapeRegex = (str) => str.replace(REGEX_SPECIAL_CHARS_GLOBAL, "\\$1");
79330
79298
  exports2.toPosixSlashes = (str) => str.replace(REGEX_BACKSLASH, "/");
79331
79299
  exports2.removeBackslashes = (str) => {
79332
- return str.replace(REGEX_REMOVE_BACKSLASH, (match12) => {
79333
- return match12 === "\\" ? "" : match12;
79300
+ return str.replace(REGEX_REMOVE_BACKSLASH, (match9) => {
79301
+ return match9 === "\\" ? "" : match9;
79334
79302
  });
79335
79303
  };
79336
79304
  exports2.supportsLookbehinds = () => {
@@ -79947,10 +79915,10 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
79947
79915
  push2({ type: "text", value: value2 });
79948
79916
  continue;
79949
79917
  }
79950
- const match12 = /^\\+/.exec(remaining());
79918
+ const match9 = /^\\+/.exec(remaining());
79951
79919
  let slashes = 0;
79952
- if (match12 && match12[0].length > 2) {
79953
- slashes = match12[0].length;
79920
+ if (match9 && match9[0].length > 2) {
79921
+ slashes = match9[0].length;
79954
79922
  state.index += slashes;
79955
79923
  if (slashes % 2 !== 0) {
79956
79924
  value2 += "\\";
@@ -80238,10 +80206,10 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
80238
80206
  if (value2 === "$" || value2 === "^") {
80239
80207
  value2 = `\\${value2}`;
80240
80208
  }
80241
- const match12 = REGEX_NON_SPECIAL_CHARS.exec(remaining());
80242
- if (match12) {
80243
- value2 += match12[0];
80244
- state.index += match12[0].length;
80209
+ const match9 = REGEX_NON_SPECIAL_CHARS.exec(remaining());
80210
+ if (match9) {
80211
+ value2 += match9[0];
80212
+ state.index += match9[0].length;
80245
80213
  }
80246
80214
  push2({ type: "text", value: value2 });
80247
80215
  continue;
@@ -80452,11 +80420,11 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
80452
80420
  case "**/.*":
80453
80421
  return `(?:${nodot}${globstar(opts)}${SLASH_LITERAL})?${DOT_LITERAL}${ONE_CHAR}${star}`;
80454
80422
  default: {
80455
- const match12 = /^(.*?)\.(\w+)$/.exec(str);
80456
- if (!match12) return;
80457
- const source3 = create(match12[1]);
80423
+ const match9 = /^(.*?)\.(\w+)$/.exec(str);
80424
+ if (!match9) return;
80425
+ const source3 = create(match9[1]);
80458
80426
  if (!source3) return;
80459
- return source3 + DOT_LITERAL + match12[2];
80427
+ return source3 + DOT_LITERAL + match9[2];
80460
80428
  }
80461
80429
  }
80462
80430
  };
@@ -80506,8 +80474,8 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
80506
80474
  isIgnored = picomatch(opts.ignore, ignoreOpts, returnState);
80507
80475
  }
80508
80476
  const matcher = (input, returnObject = false) => {
80509
- const { isMatch, match: match12, output } = picomatch.test(input, regex, options, { glob, posix });
80510
- const result = { glob, state, regex, posix, input, output, match: match12, isMatch };
80477
+ const { isMatch, match: match9, output } = picomatch.test(input, regex, options, { glob, posix });
80478
+ const result = { glob, state, regex, posix, input, output, match: match9, isMatch };
80511
80479
  if (typeof opts.onResult === "function") {
80512
80480
  opts.onResult(result);
80513
80481
  }
@@ -80541,20 +80509,20 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
80541
80509
  }
80542
80510
  const opts = options || {};
80543
80511
  const format = opts.format || (posix ? utils.toPosixSlashes : null);
80544
- let match12 = input === glob;
80545
- let output = match12 && format ? format(input) : input;
80546
- if (match12 === false) {
80512
+ let match9 = input === glob;
80513
+ let output = match9 && format ? format(input) : input;
80514
+ if (match9 === false) {
80547
80515
  output = format ? format(input) : input;
80548
- match12 = output === glob;
80516
+ match9 = output === glob;
80549
80517
  }
80550
- if (match12 === false || opts.capture === true) {
80518
+ if (match9 === false || opts.capture === true) {
80551
80519
  if (opts.matchBase === true || opts.basename === true) {
80552
- match12 = picomatch.matchBase(input, regex, options, posix);
80520
+ match9 = picomatch.matchBase(input, regex, options, posix);
80553
80521
  } else {
80554
- match12 = regex.exec(output);
80522
+ match9 = regex.exec(output);
80555
80523
  }
80556
80524
  }
80557
- return { isMatch: Boolean(match12), match: match12, output };
80525
+ return { isMatch: Boolean(match9), match: match9, output };
80558
80526
  };
80559
80527
  picomatch.matchBase = (input, glob, options, posix = utils.isWindows(options)) => {
80560
80528
  const regex = glob instanceof RegExp ? glob : picomatch.makeRe(glob, options);
@@ -80713,10 +80681,10 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
80713
80681
  if (typeof str !== "string" || str === "") {
80714
80682
  return false;
80715
80683
  }
80716
- var match12;
80717
- while (match12 = /(\\).|([@?!+*]\(.*\))/g.exec(str)) {
80718
- if (match12[2]) return true;
80719
- str = str.slice(match12.index + match12[0].length);
80684
+ var match9;
80685
+ while (match9 = /(\\).|([@?!+*]\(.*\))/g.exec(str)) {
80686
+ if (match9[2]) return true;
80687
+ str = str.slice(match9.index + match9[0].length);
80720
80688
  }
80721
80689
  return false;
80722
80690
  };
@@ -84462,17 +84430,17 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
84462
84430
  for (; ; ) {
84463
84431
  skipWhiteSpace.lastIndex = start;
84464
84432
  start += skipWhiteSpace.exec(this.input)[0].length;
84465
- var match12 = literal2.exec(this.input.slice(start));
84466
- if (!match12) {
84433
+ var match9 = literal2.exec(this.input.slice(start));
84434
+ if (!match9) {
84467
84435
  return false;
84468
84436
  }
84469
- if ((match12[1] || match12[2]) === "use strict") {
84470
- skipWhiteSpace.lastIndex = start + match12[0].length;
84437
+ if ((match9[1] || match9[2]) === "use strict") {
84438
+ skipWhiteSpace.lastIndex = start + match9[0].length;
84471
84439
  var spaceAfter = skipWhiteSpace.exec(this.input), end = spaceAfter.index + spaceAfter[0].length;
84472
84440
  var next = this.input.charAt(end);
84473
84441
  return next === ";" || next === "}" || lineBreak.test(spaceAfter[0]) && !(/[(`.[+\-/*%<>=,?^&]/.test(next) || next === "!" && this.input.charAt(end + 1) === "=");
84474
84442
  }
84475
- start += match12[0].length;
84443
+ start += match9[0].length;
84476
84444
  skipWhiteSpace.lastIndex = start;
84477
84445
  start += skipWhiteSpace.exec(this.input)[0].length;
84478
84446
  if (this.input[start] === ";") {
@@ -89918,17 +89886,17 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
89918
89886
  var streamChunksOfRawSource = (source2, onChunk, onSource, onName) => {
89919
89887
  let line2 = 1;
89920
89888
  const matches = splitIntoLines(source2);
89921
- let match12;
89922
- for (match12 of matches) {
89923
- onChunk(match12, line2, 0, -1, -1, -1, -1);
89889
+ let match9;
89890
+ for (match9 of matches) {
89891
+ onChunk(match9, line2, 0, -1, -1, -1, -1);
89924
89892
  line2++;
89925
89893
  }
89926
- return matches.length === 0 || match12.endsWith("\n") ? {
89894
+ return matches.length === 0 || match9.endsWith("\n") ? {
89927
89895
  generatedLine: matches.length + 1,
89928
89896
  generatedColumn: 0
89929
89897
  } : {
89930
89898
  generatedLine: matches.length,
89931
- generatedColumn: match12.length
89899
+ generatedColumn: match9.length
89932
89900
  };
89933
89901
  };
89934
89902
  module2.exports = (source2, onChunk, onSource, onName, finalSource) => {
@@ -90362,19 +90330,19 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
90362
90330
  let line2 = 1;
90363
90331
  let column2 = 0;
90364
90332
  if (matches !== null) {
90365
- for (const match12 of matches) {
90366
- const isEndOfLine = match12.endsWith("\n");
90367
- if (isEndOfLine && match12.length === 1) {
90368
- if (!finalSource) onChunk(match12, line2, column2, -1, -1, -1, -1);
90333
+ for (const match9 of matches) {
90334
+ const isEndOfLine = match9.endsWith("\n");
90335
+ if (isEndOfLine && match9.length === 1) {
90336
+ if (!finalSource) onChunk(match9, line2, column2, -1, -1, -1, -1);
90369
90337
  } else {
90370
- const chunk = finalSource ? void 0 : match12;
90338
+ const chunk = finalSource ? void 0 : match9;
90371
90339
  onChunk(chunk, line2, column2, 0, line2, column2, -1);
90372
90340
  }
90373
90341
  if (isEndOfLine) {
90374
90342
  line2++;
90375
90343
  column2 = 0;
90376
90344
  } else {
90377
- column2 += match12.length;
90345
+ column2 += match9.length;
90378
90346
  }
90379
90347
  }
90380
90348
  }
@@ -90397,18 +90365,18 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
90397
90365
  } else {
90398
90366
  let line2 = 1;
90399
90367
  const matches = splitIntoLines(this._value);
90400
- let match12;
90401
- for (match12 of matches) {
90402
- onChunk(finalSource ? void 0 : match12, line2, 0, 0, line2, 0, -1);
90368
+ let match9;
90369
+ for (match9 of matches) {
90370
+ onChunk(finalSource ? void 0 : match9, line2, 0, 0, line2, 0, -1);
90403
90371
  line2++;
90404
90372
  }
90405
- return matches.length === 0 || match12.endsWith("\n") ? {
90373
+ return matches.length === 0 || match9.endsWith("\n") ? {
90406
90374
  generatedLine: matches.length + 1,
90407
90375
  generatedColumn: 0,
90408
90376
  source: finalSource ? this._value : void 0
90409
90377
  } : {
90410
90378
  generatedLine: matches.length,
90411
- generatedColumn: match12.length,
90379
+ generatedColumn: match9.length,
90412
90380
  source: finalSource ? this._value : void 0
90413
90381
  };
90414
90382
  }
@@ -92681,13 +92649,13 @@ It seems like none of the "@sentry/cli" package's optional dependencies got inst
92681
92649
  return input.startsWith("/");
92682
92650
  }
92683
92651
  function parseAbsoluteUrl(input) {
92684
- const match12 = urlRegex.exec(input);
92652
+ const match9 = urlRegex.exec(input);
92685
92653
  return {
92686
- scheme: match12[1],
92687
- user: match12[2] || "",
92688
- host: match12[3],
92689
- port: match12[4] || "",
92690
- path: match12[5] || "/",
92654
+ scheme: match9[1],
92655
+ user: match9[2] || "",
92656
+ host: match9[3],
92657
+ port: match9[4] || "",
92658
+ path: match9[5] || "/",
92691
92659
  relativePath: false
92692
92660
  };
92693
92661
  }
@@ -94003,10 +93971,10 @@ Did you specify these with the most recent transformation maps first?`);
94003
93971
  const obj = {};
94004
93972
  let lines = src.toString();
94005
93973
  lines = lines.replace(/\r\n?/mg, "\n");
94006
- let match12;
94007
- while ((match12 = LINE.exec(lines)) != null) {
94008
- const key2 = match12[1];
94009
- let value2 = match12[2] || "";
93974
+ let match9;
93975
+ while ((match9 = LINE.exec(lines)) != null) {
93976
+ const key2 = match9[1];
93977
+ let value2 = match9[2] || "";
94010
93978
  value2 = value2.trim();
94011
93979
  const maybeQuote = value2[0];
94012
93980
  value2 = value2.replace(/^(['"`])([\s\S]*)\1$/mg, "$2");
@@ -95203,14 +95171,14 @@ Did you specify these with the most recent transformation maps first?`);
95203
95171
  return `${protocol}://${publicKey}${withPassword && pass ? `:${pass}` : ""}@${host}${port ? `:${port}` : ""}/${path2 ? `${path2}/` : path2}${projectId}`;
95204
95172
  }
95205
95173
  function dsnFromString2(str) {
95206
- const match12 = DSN_REGEX.exec(str);
95207
- if (!match12) {
95174
+ const match9 = DSN_REGEX.exec(str);
95175
+ if (!match9) {
95208
95176
  consoleSandbox(() => {
95209
95177
  console.error(`Invalid Sentry Dsn: ${str}`);
95210
95178
  });
95211
95179
  return void 0;
95212
95180
  }
95213
- const [protocol, publicKey, pass = "", host = "", port = "", lastPath = ""] = match12.slice(1);
95181
+ const [protocol, publicKey, pass = "", host = "", port = "", lastPath = ""] = match9.slice(1);
95214
95182
  let path2 = "";
95215
95183
  let projectId = lastPath;
95216
95184
  const split = projectId.split("/");
@@ -98372,12 +98340,12 @@ ${JSON.stringify(itemHeaders)}
98372
98340
  });
98373
98341
  }
98374
98342
  function applyClientOptions(event, options) {
98375
- const { environment, release, dist, maxValueLength = 250 } = options;
98343
+ const { environment, release: release2, dist, maxValueLength = 250 } = options;
98376
98344
  if (!("environment" in event)) {
98377
98345
  event.environment = "environment" in options ? environment : DEFAULT_ENVIRONMENT;
98378
98346
  }
98379
- if (event.release === void 0 && release !== void 0) {
98380
- event.release = release;
98347
+ if (event.release === void 0 && release2 !== void 0) {
98348
+ event.release = release2;
98381
98349
  }
98382
98350
  if (event.dist === void 0 && dist !== void 0) {
98383
98351
  event.dist = dist;
@@ -99357,12 +99325,12 @@ Reason: ${reason}`
99357
99325
  }
99358
99326
  /** Method that initialises an instance of SessionFlusher on Client */
99359
99327
  initSessionFlusher() {
99360
- const { release, environment } = this._options;
99361
- if (!release) {
99328
+ const { release: release2, environment } = this._options;
99329
+ if (!release2) {
99362
99330
  DEBUG_BUILD && logger.warn("Cannot initialise an instance of SessionFlusher if no release is provided!");
99363
99331
  } else {
99364
99332
  this._sessionFlusher = new SessionFlusher(this, {
99365
- release,
99333
+ release: release2,
99366
99334
  environment
99367
99335
  });
99368
99336
  }
@@ -99381,12 +99349,12 @@ Reason: ${reason}`
99381
99349
  return id;
99382
99350
  }
99383
99351
  const options = this.getOptions();
99384
- const { release, environment, tunnel } = options;
99352
+ const { release: release2, environment, tunnel } = options;
99385
99353
  const serializedCheckIn = {
99386
99354
  check_in_id: id,
99387
99355
  monitor_slug: checkIn.monitorSlug,
99388
99356
  status: checkIn.status,
99389
- release,
99357
+ release: release2,
99390
99358
  environment
99391
99359
  };
99392
99360
  if ("duration" in checkIn) {
@@ -99561,9 +99529,9 @@ Reason: ${reason}`
99561
99529
  version = version.slice(1);
99562
99530
  }
99563
99531
  var regex = /^[\^~]?(\d+)(\.\d+)?(\.\d+)?(-.+)?/;
99564
- var match12 = version.match(regex);
99565
- if (match12) {
99566
- return parseInt(match12[1], 10);
99532
+ var match9 = version.match(regex);
99533
+ if (match9) {
99534
+ return parseInt(match9[1], 10);
99567
99535
  }
99568
99536
  var coerced = parseInt(version, 10);
99569
99537
  if (!Number.isNaN(coerced)) {
@@ -99697,8 +99665,8 @@ Reason: ${reason}`
99697
99665
  return possibleReleaseNameOfGitProvider || possibleReleaseNameOfCiProvidersWithSpecificEnvVar || possibleReleaseNameOfCiProvidersWithGenericEnvVar || gitRevision();
99698
99666
  }
99699
99667
  function generateGlobalInjectorCode(_ref2) {
99700
- var release = _ref2.release, injectBuildInformation = _ref2.injectBuildInformation;
99701
- var code = "{\n let _global =\n typeof window !== 'undefined' ?\n window :\n typeof global !== 'undefined' ?\n global :\n typeof globalThis !== 'undefined' ?\n globalThis :\n typeof self !== 'undefined' ?\n self :\n {};\n\n _global.SENTRY_RELEASE={id:".concat(JSON.stringify(release), "};");
99668
+ var release2 = _ref2.release, injectBuildInformation = _ref2.injectBuildInformation;
99669
+ var code = "{\n let _global =\n typeof window !== 'undefined' ?\n window :\n typeof global !== 'undefined' ?\n global :\n typeof globalThis !== 'undefined' ?\n globalThis :\n typeof self !== 'undefined' ?\n self :\n {};\n\n _global.SENTRY_RELEASE={id:".concat(JSON.stringify(release2), "};");
99702
99670
  if (injectBuildInformation) {
99703
99671
  var buildInfo = getBuildInformation$1();
99704
99672
  code += "\n _global.SENTRY_BUILD_INFO=".concat(JSON.stringify(buildInfo), ";");
@@ -100012,20 +99980,20 @@ Reason: ${reason}`
100012
99980
  }
100013
99981
  function setTelemetryDataOnScope(options, scope, buildTool) {
100014
99982
  var _options$_metaOptions;
100015
- var org = options.org, project = options.project, release = options.release, errorHandler = options.errorHandler, sourcemaps = options.sourcemaps, reactComponentAnnotation = options.reactComponentAnnotation;
100016
- scope.setTag("upload-legacy-sourcemaps", !!release.uploadLegacySourcemaps);
100017
- if (release.uploadLegacySourcemaps) {
100018
- scope.setTag("uploadLegacySourcemapsEntries", Array.isArray(release.uploadLegacySourcemaps) ? release.uploadLegacySourcemaps.length : 1);
99983
+ var org = options.org, project = options.project, release2 = options.release, errorHandler = options.errorHandler, sourcemaps = options.sourcemaps, reactComponentAnnotation = options.reactComponentAnnotation;
99984
+ scope.setTag("upload-legacy-sourcemaps", !!release2.uploadLegacySourcemaps);
99985
+ if (release2.uploadLegacySourcemaps) {
99986
+ scope.setTag("uploadLegacySourcemapsEntries", Array.isArray(release2.uploadLegacySourcemaps) ? release2.uploadLegacySourcemaps.length : 1);
100019
99987
  }
100020
99988
  scope.setTag("module-metadata", !!options.moduleMetadata);
100021
99989
  scope.setTag("inject-build-information", !!options._experiments.injectBuildInformation);
100022
- if (release.setCommits) {
100023
- scope.setTag("set-commits", release.setCommits.auto === true ? "auto" : "manual");
99990
+ if (release2.setCommits) {
99991
+ scope.setTag("set-commits", release2.setCommits.auto === true ? "auto" : "manual");
100024
99992
  } else {
100025
99993
  scope.setTag("set-commits", "undefined");
100026
99994
  }
100027
- scope.setTag("finalize-release", release.finalize);
100028
- scope.setTag("deploy-options", !!release.deploy);
99995
+ scope.setTag("finalize-release", release2.finalize);
99996
+ scope.setTag("deploy-options", !!release2.deploy);
100029
99997
  scope.setTag("custom-error-handler", !!errorHandler);
100030
99998
  scope.setTag("sourcemaps-assets", !!(sourcemaps !== null && sourcemaps !== void 0 && sourcemaps.assets));
100031
99999
  scope.setTag("delete-after-upload", !!(sourcemaps !== null && sourcemaps !== void 0 && sourcemaps.filesToDeleteAfterUpload));
@@ -100051,11 +100019,11 @@ Reason: ${reason}`
100051
100019
  function _allowedToSendTelemetry() {
100052
100020
  _allowedToSendTelemetry = _asyncToGenerator(/* @__PURE__ */ _regeneratorRuntime().mark(function _callee(options) {
100053
100021
  var _cliInfo$split$, _cliInfo$split$$repla;
100054
- var silent, org, project, authToken, url2, headers, telemetry, release, cli, cliInfo, cliInfoUrl;
100022
+ var silent, org, project, authToken, url2, headers, telemetry, release2, cli, cliInfo, cliInfoUrl;
100055
100023
  return _regeneratorRuntime().wrap(function _callee$(_context) {
100056
100024
  while (1) switch (_context.prev = _context.next) {
100057
100025
  case 0:
100058
- silent = options.silent, org = options.org, project = options.project, authToken = options.authToken, url2 = options.url, headers = options.headers, telemetry = options.telemetry, release = options.release;
100026
+ silent = options.silent, org = options.org, project = options.project, authToken = options.authToken, url2 = options.url, headers = options.headers, telemetry = options.telemetry, release2 = options.release;
100059
100027
  if (!(telemetry === false)) {
100060
100028
  _context.next = 3;
100061
100029
  break;
@@ -100073,7 +100041,7 @@ Reason: ${reason}`
100073
100041
  authToken,
100074
100042
  org,
100075
100043
  project,
100076
- vcsRemote: release.vcsRemote,
100044
+ vcsRemote: release2.vcsRemote,
100077
100045
  silent,
100078
100046
  headers
100079
100047
  });
@@ -100218,9 +100186,9 @@ Reason: ${reason}`
100218
100186
  return _prepareBundleForDebugIdUpload.apply(this, arguments);
100219
100187
  }
100220
100188
  function determineDebugIdFromBundleSource(code) {
100221
- var match12 = code.match(/sentry-dbid-([0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12})/);
100222
- if (match12) {
100223
- return match12[1];
100189
+ var match9 = code.match(/sentry-dbid-([0-9a-fA-F]{8}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{4}\b-[0-9a-fA-F]{12})/);
100190
+ if (match9) {
100191
+ return match9[1];
100224
100192
  } else {
100225
100193
  return void 0;
100226
100194
  }
@@ -100474,9 +100442,9 @@ Reason: ${reason}`
100474
100442
  }
100475
100443
  var shouldSendTelemetry = allowedToSendTelemetry(options);
100476
100444
  var _createSentryInstance = createSentryInstance(options, shouldSendTelemetry, bundlerPluginMetaContext.buildTool), sentryScope = _createSentryInstance.sentryScope, sentryClient = _createSentryInstance.sentryClient;
100477
- var _sentryClient$getOpti = sentryClient.getOptions(), release = _sentryClient$getOpti.release, _sentryClient$getOpti2 = _sentryClient$getOpti.environment, environment = _sentryClient$getOpti2 === void 0 ? DEFAULT_ENVIRONMENT : _sentryClient$getOpti2;
100445
+ var _sentryClient$getOpti = sentryClient.getOptions(), release2 = _sentryClient$getOpti.release, _sentryClient$getOpti2 = _sentryClient$getOpti.environment, environment = _sentryClient$getOpti2 === void 0 ? DEFAULT_ENVIRONMENT : _sentryClient$getOpti2;
100478
100446
  var sentrySession = makeSession({
100479
- release,
100447
+ release: release2,
100480
100448
  environment
100481
100449
  });
100482
100450
  sentryScope.setSession(sentrySession);
@@ -101381,9 +101349,9 @@ Reason: ${reason}`
101381
101349
  var ms = new MagicString__default["default"](code, {
101382
101350
  filename: chunk.fileName
101383
101351
  });
101384
- var match12 = (_code$match = code.match(COMMENT_USE_STRICT_REGEX)) === null || _code$match === void 0 ? void 0 : _code$match[0];
101385
- if (match12) {
101386
- ms.appendLeft(match12.length, codeToInject);
101352
+ var match9 = (_code$match = code.match(COMMENT_USE_STRICT_REGEX)) === null || _code$match === void 0 ? void 0 : _code$match[0];
101353
+ if (match9) {
101354
+ ms.appendLeft(match9.length, codeToInject);
101387
101355
  } else {
101388
101356
  ms.prepend(codeToInject);
101389
101357
  }
@@ -101413,9 +101381,9 @@ Reason: ${reason}`
101413
101381
  var ms = new MagicString__default["default"](code, {
101414
101382
  filename: chunk.fileName
101415
101383
  });
101416
- var match12 = (_code$match2 = code.match(COMMENT_USE_STRICT_REGEX)) === null || _code$match2 === void 0 ? void 0 : _code$match2[0];
101417
- if (match12) {
101418
- ms.appendLeft(match12.length, injectionCode);
101384
+ var match9 = (_code$match2 = code.match(COMMENT_USE_STRICT_REGEX)) === null || _code$match2 === void 0 ? void 0 : _code$match2[0];
101385
+ if (match9) {
101386
+ ms.appendLeft(match9.length, injectionCode);
101419
101387
  } else {
101420
101388
  ms.prepend(injectionCode);
101421
101389
  }
@@ -105824,24 +105792,24 @@ Reason: ${reason}`
105824
105792
  });
105825
105793
  module2.exports = __toCommonJS2(vite_exports);
105826
105794
  var import_vite_plugin = require_cjs5();
105827
- var import_zod3 = require_zod();
105828
- var providerSchema = import_zod3.z.discriminatedUnion("type", [
105829
- import_zod3.z.object({
105830
- type: import_zod3.z.literal("SENTRY"),
105831
- sentryOptions: import_zod3.z.object({
105832
- dsn: import_zod3.z.string().url()
105795
+ var import_zod4 = require_zod();
105796
+ var providerSchema = import_zod4.z.discriminatedUnion("type", [
105797
+ import_zod4.z.object({
105798
+ type: import_zod4.z.literal("SENTRY"),
105799
+ sentryOptions: import_zod4.z.object({
105800
+ dsn: import_zod4.z.string().url()
105833
105801
  })
105834
105802
  }),
105835
- import_zod3.z.object({
105836
- type: import_zod3.z.literal("PANORAMA"),
105837
- panoramaOptions: import_zod3.z.object({
105838
- sentry: import_zod3.z.object({
105839
- dsn: import_zod3.z.string().url()
105803
+ import_zod4.z.object({
105804
+ type: import_zod4.z.literal("PANORAMA"),
105805
+ panoramaOptions: import_zod4.z.object({
105806
+ sentry: import_zod4.z.object({
105807
+ dsn: import_zod4.z.string().url()
105840
105808
  }).optional(),
105841
- project: import_zod3.z.object({
105842
- groupId: import_zod3.z.string(),
105843
- artifactId: import_zod3.z.string(),
105844
- fingerprint: import_zod3.z.string()
105809
+ project: import_zod4.z.object({
105810
+ groupId: import_zod4.z.string(),
105811
+ artifactId: import_zod4.z.string(),
105812
+ fingerprint: import_zod4.z.string()
105845
105813
  })
105846
105814
  })
105847
105815
  })
@@ -105877,10 +105845,10 @@ ${error.errors.map(formatZodIssue).join("\n")}`,
105877
105845
  const pluginOrArray = (0, import_vite_plugin.sentryVitePlugin)({
105878
105846
  silent,
105879
105847
  debug,
105880
- moduleMetadata: ({ release }) => ({
105848
+ moduleMetadata: ({ release: release2 }) => ({
105881
105849
  appId,
105882
105850
  dsn,
105883
- release,
105851
+ release: release2,
105884
105852
  ...extra
105885
105853
  })
105886
105854
  });
@@ -106036,11 +106004,11 @@ ${error.errors.map(formatZodIssue).join("\n")}`,
106036
106004
  };
106037
106005
  }
106038
106006
  function dsnFromString(str) {
106039
- const match12 = SENTRY_DSN_REGEX.exec(str);
106040
- if (!match12) {
106007
+ const match9 = SENTRY_DSN_REGEX.exec(str);
106008
+ if (!match9) {
106041
106009
  throw new Error("Invalid DSN");
106042
106010
  }
106043
- const [protocol, publicKey, pass = "", host = "", port = "", lastPath = ""] = match12.slice(1);
106011
+ const [protocol, publicKey, pass = "", host = "", port = "", lastPath = ""] = match9.slice(1);
106044
106012
  let path = "";
106045
106013
  let projectId = lastPath;
106046
106014
  const split = projectId.split("/");
@@ -106151,150 +106119,613 @@ window.sentryOnLoad = function () {
106151
106119
  }
106152
106120
  });
106153
106121
 
106154
- // ../cli-astro-commands/src/components/DevCommand/index.ts
106122
+ // ../arm-client/src/useARMClient.ts
106155
106123
  init_esm_shims();
106124
+ var import_react = __toESM(require_react(), 1);
106156
106125
 
106157
- // ../cli-astro-commands/src/components/DevCommand/DevCommand.tsx
106126
+ // ../arm-client/src/client.ts
106158
106127
  init_esm_shims();
106159
- var import_react27 = __toESM(require_react(), 1);
106160
106128
 
106161
- // ../cli-astro-commands/src/components/DevCommand/utils/runAstroDev.ts
106129
+ // ../../node_modules/@wix/ambassador-ctp-gradual-rollout-v1-app-config/build/es/http.impl.js
106162
106130
  init_esm_shims();
106163
- var EVENT_LINE = "line";
106164
- var EVENT_SERVER_ADDRESS = "server_address";
106165
- function runAstroDev({
106166
- packageManager,
106167
- projectFolder,
106168
- port,
106169
- allowedHosts
106170
- }) {
106171
- const binaryArgs = ["astro", "dev"];
106172
- if (port) {
106173
- binaryArgs.push("--port", `${port}`);
106131
+ var _commitComponentOverrideRequest = {};
106132
+ var _commitComponentOverrideResponse = {};
106133
+ var _createAppReleaseRequest = {};
106134
+ var _createAppReleaseResponse = {};
106135
+ var _createComponentsRequest = {};
106136
+ var _createComponentsResponse = {};
106137
+ var _promoteAppVersionFromDraftToProductionRequest = {};
106138
+ var _promoteAppVersionFromDraftToProductionResponse = {};
106139
+ var _updateAppReleaseRequest = {};
106140
+ var _updateAppReleaseResponse = {};
106141
+ function resolveComWixCtpAppsReleaseManagerServiceUrl(opts) {
106142
+ var domainToMappings = {
106143
+ "api._api_base_domain_": [
106144
+ {
106145
+ srcPath: "/apps-release-manager-service-web",
106146
+ destPath: ""
106147
+ }
106148
+ ],
106149
+ "bo._base_domain_": [
106150
+ {
106151
+ srcPath: "/apps-release-manager-service-web",
106152
+ destPath: ""
106153
+ }
106154
+ ],
106155
+ "wixbo.ai": [
106156
+ {
106157
+ srcPath: "/apps-release-manager-service-web",
106158
+ destPath: ""
106159
+ }
106160
+ ],
106161
+ "wix-bo.com": [
106162
+ {
106163
+ srcPath: "/apps-release-manager-service-web",
106164
+ destPath: ""
106165
+ }
106166
+ ],
106167
+ "www._base_domain_": [
106168
+ {
106169
+ srcPath: "/apps-release-manager-service-web/artifacts-release-manager/app-releases",
106170
+ destPath: "/artifacts-release-manager/app-releases"
106171
+ },
106172
+ {
106173
+ srcPath: "/_api/apps-release-manager-service-web/artifacts-release-manager/app-releases",
106174
+ destPath: "/artifacts-release-manager/app-releases"
106175
+ },
106176
+ {
106177
+ srcPath: "/apps-release-manager-service-web/apps/create",
106178
+ destPath: "/apps/create"
106179
+ },
106180
+ {
106181
+ srcPath: "/apps-release-manager-service-web/apps/promote",
106182
+ destPath: "/apps/promote"
106183
+ },
106184
+ {
106185
+ srcPath: "/apps-release-manager-service-web/apps/tags",
106186
+ destPath: "/apps/tags"
106187
+ },
106188
+ {
106189
+ srcPath: "/apps-release-manager-service-web/apps/create-components",
106190
+ destPath: "/apps/create-components"
106191
+ },
106192
+ {
106193
+ srcPath: "/apps-release-manager-service-web/apps/commit",
106194
+ destPath: "/apps/commit"
106195
+ },
106196
+ {
106197
+ srcPath: "/apps-release-manager-service-web/apps/promote-app-version",
106198
+ destPath: "/apps/promote-app-version"
106199
+ }
106200
+ ],
106201
+ "manage._base_domain_": [
106202
+ {
106203
+ srcPath: "/apps-release-manager-service-web/apps/promote",
106204
+ destPath: "/apps/promote"
106205
+ },
106206
+ {
106207
+ srcPath: "/apps-release-manager-service-web/apps/create",
106208
+ destPath: "/apps/create"
106209
+ },
106210
+ {
106211
+ srcPath: "/apps-release-manager-service-web/apps/tags",
106212
+ destPath: "/apps/tags"
106213
+ },
106214
+ {
106215
+ srcPath: "/apps-release-manager-service-web/apps/create-components",
106216
+ destPath: "/apps/create-components"
106217
+ },
106218
+ {
106219
+ srcPath: "/apps-release-manager-service-web/apps/commit",
106220
+ destPath: "/apps/commit"
106221
+ },
106222
+ {
106223
+ srcPath: "/apps-release-manager-service-web/apps/promote-app-version",
106224
+ destPath: "/apps/promote-app-version"
106225
+ },
106226
+ {
106227
+ srcPath: "/apps-release-manager-service-web/apps/release",
106228
+ destPath: "/apps/release"
106229
+ }
106230
+ ]
106231
+ };
106232
+ return resolveUrl(Object.assign(opts, { domainToMappings }));
106233
+ }
106234
+ function createAppRelease(payload) {
106235
+ var _a = serializer(_createAppReleaseRequest, {}), toReq = _a.toJSON, fromReq = _a.fromJSON;
106236
+ var fromRes = serializer(_createAppReleaseResponse, {}).fromJSON;
106237
+ function __createAppRelease(_a2) {
106238
+ var host = _a2.host;
106239
+ var serializedData = toReq(payload);
106240
+ var metadata = {
106241
+ entityFqdn: "wix.ctp.gradual_rollout.v1.app_config",
106242
+ method: "POST",
106243
+ methodFqn: "com.wix.ctp.AppsReleaseManagerService.CreateAppRelease",
106244
+ migrationOptions: {
106245
+ optInTransformResponse: true
106246
+ },
106247
+ url: resolveComWixCtpAppsReleaseManagerServiceUrl({
106248
+ protoPath: "/apps/create/{appId}",
106249
+ data: serializedData,
106250
+ host
106251
+ }),
106252
+ data: serializedData,
106253
+ transformResponse: fromRes
106254
+ };
106255
+ return metadata;
106256
+ }
106257
+ __createAppRelease.fromReq = fromReq;
106258
+ __createAppRelease.__isAmbassador = true;
106259
+ return __createAppRelease;
106260
+ }
106261
+ function updateAppRelease(payload) {
106262
+ var _a = serializer(_updateAppReleaseRequest, {}), toReq = _a.toJSON, fromReq = _a.fromJSON;
106263
+ var fromRes = serializer(_updateAppReleaseResponse, {}).fromJSON;
106264
+ function __updateAppRelease(_a2) {
106265
+ var host = _a2.host;
106266
+ var serializedData = toReq(payload);
106267
+ var metadata = {
106268
+ entityFqdn: "wix.ctp.gradual_rollout.v1.app_config",
106269
+ method: "PUT",
106270
+ methodFqn: "com.wix.ctp.AppsReleaseManagerService.UpdateAppRelease",
106271
+ migrationOptions: {
106272
+ optInTransformResponse: true
106273
+ },
106274
+ url: resolveComWixCtpAppsReleaseManagerServiceUrl({
106275
+ protoPath: "/apps/tags/{tag}",
106276
+ data: serializedData,
106277
+ host
106278
+ }),
106279
+ data: serializedData,
106280
+ transformResponse: fromRes
106281
+ };
106282
+ return metadata;
106174
106283
  }
106175
- if (allowedHosts) {
106176
- binaryArgs.push("--allowed-hosts", allowedHosts);
106284
+ __updateAppRelease.fromReq = fromReq;
106285
+ __updateAppRelease.__isAmbassador = true;
106286
+ return __updateAppRelease;
106287
+ }
106288
+ function createComponents(payload) {
106289
+ var _a = serializer(_createComponentsRequest, {}), toReq = _a.toJSON, fromReq = _a.fromJSON;
106290
+ var fromRes = serializer(_createComponentsResponse, {}).fromJSON;
106291
+ function __createComponents(_a2) {
106292
+ var host = _a2.host;
106293
+ var serializedData = toReq(payload);
106294
+ var metadata = {
106295
+ entityFqdn: "wix.ctp.gradual_rollout.v1.app_config",
106296
+ method: "POST",
106297
+ methodFqn: "com.wix.ctp.AppsReleaseManagerService.CreateComponents",
106298
+ migrationOptions: {
106299
+ optInTransformResponse: true
106300
+ },
106301
+ url: resolveComWixCtpAppsReleaseManagerServiceUrl({
106302
+ protoPath: "/apps/create-components/{appId}",
106303
+ data: serializedData,
106304
+ host
106305
+ }),
106306
+ data: serializedData,
106307
+ transformResponse: fromRes
106308
+ };
106309
+ return metadata;
106177
106310
  }
106178
- const { file, args } = packageManager.getRunBinaryCmd(binaryArgs);
106179
- const result = execa(file, args, {
106180
- cwd: projectFolder,
106181
- stdio: "pipe",
106182
- env: { FORCE_COLOR: "1" },
106183
- cleanup: true,
106184
- windowsHide: false
106185
- });
106186
- let stdoutBuffer = "";
106187
- result.stdout?.on("data", (chunk) => {
106188
- stdoutBuffer += chunk.toString();
106189
- const lines = stdoutBuffer.split("\n");
106190
- stdoutBuffer = lines.pop() ?? "";
106191
- for (const line of lines) {
106192
- result.stdout?.emit(EVENT_LINE, line);
106193
- if (line.includes("http://")) {
106194
- const match12 = /(http:\/\/[^\s]+)/.exec(line);
106195
- if (match12?.[1]) {
106196
- const address = stripAnsi(match12[1]).trim();
106197
- result.stdout?.emit(EVENT_SERVER_ADDRESS, address);
106198
- }
106199
- }
106200
- }
106201
- });
106202
- let stdErrBuffer = "";
106203
- result.stderr?.on("data", (chunk) => {
106204
- stdErrBuffer += chunk.toString();
106205
- const lines = stdErrBuffer.split("\n");
106206
- stdErrBuffer = lines.pop() ?? "";
106207
- for (const line of lines) {
106208
- result.stderr?.emit(EVENT_LINE, line);
106209
- }
106210
- });
106211
- return result;
106311
+ __createComponents.fromReq = fromReq;
106312
+ __createComponents.__isAmbassador = true;
106313
+ return __createComponents;
106314
+ }
106315
+ function commitComponentOverride(payload) {
106316
+ var _a = serializer(_commitComponentOverrideRequest, {}), toReq = _a.toJSON, fromReq = _a.fromJSON;
106317
+ var fromRes = serializer(_commitComponentOverrideResponse, {}).fromJSON;
106318
+ function __commitComponentOverride(_a2) {
106319
+ var host = _a2.host;
106320
+ var serializedData = toReq(payload);
106321
+ var metadata = {
106322
+ entityFqdn: "wix.ctp.gradual_rollout.v1.app_config",
106323
+ method: "POST",
106324
+ methodFqn: "com.wix.ctp.AppsReleaseManagerService.CommitComponentOverride",
106325
+ migrationOptions: {
106326
+ optInTransformResponse: true
106327
+ },
106328
+ url: resolveComWixCtpAppsReleaseManagerServiceUrl({
106329
+ protoPath: "/apps/commit/{appId}/{componentOverrideId}",
106330
+ data: serializedData,
106331
+ host
106332
+ }),
106333
+ data: serializedData,
106334
+ transformResponse: fromRes
106335
+ };
106336
+ return metadata;
106337
+ }
106338
+ __commitComponentOverride.fromReq = fromReq;
106339
+ __commitComponentOverride.__isAmbassador = true;
106340
+ return __commitComponentOverride;
106341
+ }
106342
+ function promoteAppVersionFromDraftToProduction(payload) {
106343
+ var _a = serializer(_promoteAppVersionFromDraftToProductionRequest, {}), toReq = _a.toJSON, fromReq = _a.fromJSON;
106344
+ var fromRes = serializer(_promoteAppVersionFromDraftToProductionResponse, {}).fromJSON;
106345
+ function __promoteAppVersionFromDraftToProduction(_a2) {
106346
+ var host = _a2.host;
106347
+ var serializedData = toReq(payload);
106348
+ var metadata = {
106349
+ entityFqdn: "wix.ctp.gradual_rollout.v1.app_config",
106350
+ method: "POST",
106351
+ methodFqn: "com.wix.ctp.AppsReleaseManagerService.PromoteAppVersionFromDraftToProduction",
106352
+ migrationOptions: {
106353
+ optInTransformResponse: true
106354
+ },
106355
+ url: resolveComWixCtpAppsReleaseManagerServiceUrl({
106356
+ protoPath: "/apps/promote-app-version/{appId}/{createNewMajor}/{latestMajor}",
106357
+ data: serializedData,
106358
+ host
106359
+ }),
106360
+ data: serializedData,
106361
+ transformResponse: fromRes
106362
+ };
106363
+ return metadata;
106364
+ }
106365
+ __promoteAppVersionFromDraftToProduction.fromReq = fromReq;
106366
+ __promoteAppVersionFromDraftToProduction.__isAmbassador = true;
106367
+ return __promoteAppVersionFromDraftToProduction;
106212
106368
  }
106213
106369
 
106214
- // ../cli-astro-commands/src/components/DevCommand/utils/createAstroLogger.tsx
106370
+ // ../../node_modules/@wix/ambassador-ctp-gradual-rollout-v1-baas-release/build/es/http.impl.js
106215
106371
  init_esm_shims();
106216
- var import_react = __toESM(require_react(), 1);
106217
- var dateTimeFormat = new Intl.DateTimeFormat([], {
106218
- hour: "2-digit",
106219
- minute: "2-digit",
106220
- second: "2-digit",
106221
- hour12: false
106222
- });
106223
- function createAstroLogger(isPrefixed = true) {
106224
- const renderer = createRendererToString({ stripAnsi: false });
106225
- const log = (msg) => {
106226
- if (typeof msg === "string") {
106227
- setTimeout(() => console.log(msg), 0);
106228
- } else {
106229
- setTimeout(() => console.log(renderer.render(msg)), 0);
106230
- }
106231
- };
106232
- const prefixedLog = (msg) => {
106233
- const timestamp = dateTimeFormat.format(/* @__PURE__ */ new Date());
106234
- const log2 = /* @__PURE__ */ import_react.default.createElement(Text, null, /* @__PURE__ */ import_react.default.createElement(Text, null, timestamp, " "), /* @__PURE__ */ import_react.default.createElement(Text, { skin: "info" }, "[wix] "), /* @__PURE__ */ import_react.default.createElement(Text, null, msg));
106235
- console.log(renderer.render(log2));
106372
+ var _releaseRequest = {};
106373
+ var _releaseResponse = {};
106374
+ function resolveComWixCtpAppsReleaseManagerBassServiceUrl(opts) {
106375
+ var domainToMappings = {
106376
+ "api._api_base_domain_": [
106377
+ {
106378
+ srcPath: "/apps-release-manager-service-web",
106379
+ destPath: ""
106380
+ }
106381
+ ],
106382
+ "bo._base_domain_": [
106383
+ {
106384
+ srcPath: "/apps-release-manager-service-web",
106385
+ destPath: ""
106386
+ }
106387
+ ],
106388
+ "wixbo.ai": [
106389
+ {
106390
+ srcPath: "/apps-release-manager-service-web",
106391
+ destPath: ""
106392
+ }
106393
+ ],
106394
+ "wix-bo.com": [
106395
+ {
106396
+ srcPath: "/apps-release-manager-service-web",
106397
+ destPath: ""
106398
+ }
106399
+ ],
106400
+ "www._base_domain_": [
106401
+ {
106402
+ srcPath: "/apps-release-manager-service-web/artifacts-release-manager/app-releases",
106403
+ destPath: "/artifacts-release-manager/app-releases"
106404
+ },
106405
+ {
106406
+ srcPath: "/_api/apps-release-manager-service-web/artifacts-release-manager/app-releases",
106407
+ destPath: "/artifacts-release-manager/app-releases"
106408
+ },
106409
+ {
106410
+ srcPath: "/apps-release-manager-service-web/apps/create",
106411
+ destPath: "/apps/create"
106412
+ },
106413
+ {
106414
+ srcPath: "/apps-release-manager-service-web/apps/promote",
106415
+ destPath: "/apps/promote"
106416
+ },
106417
+ {
106418
+ srcPath: "/apps-release-manager-service-web/apps/tags",
106419
+ destPath: "/apps/tags"
106420
+ },
106421
+ {
106422
+ srcPath: "/apps-release-manager-service-web/apps/create-components",
106423
+ destPath: "/apps/create-components"
106424
+ },
106425
+ {
106426
+ srcPath: "/apps-release-manager-service-web/apps/commit",
106427
+ destPath: "/apps/commit"
106428
+ },
106429
+ {
106430
+ srcPath: "/apps-release-manager-service-web/apps/promote-app-version",
106431
+ destPath: "/apps/promote-app-version"
106432
+ }
106433
+ ],
106434
+ "manage._base_domain_": [
106435
+ {
106436
+ srcPath: "/apps-release-manager-service-web/apps/promote",
106437
+ destPath: "/apps/promote"
106438
+ },
106439
+ {
106440
+ srcPath: "/apps-release-manager-service-web/apps/create",
106441
+ destPath: "/apps/create"
106442
+ },
106443
+ {
106444
+ srcPath: "/apps-release-manager-service-web/apps/tags",
106445
+ destPath: "/apps/tags"
106446
+ },
106447
+ {
106448
+ srcPath: "/apps-release-manager-service-web/apps/create-components",
106449
+ destPath: "/apps/create-components"
106450
+ },
106451
+ {
106452
+ srcPath: "/apps-release-manager-service-web/apps/commit",
106453
+ destPath: "/apps/commit"
106454
+ },
106455
+ {
106456
+ srcPath: "/apps-release-manager-service-web/apps/promote-app-version",
106457
+ destPath: "/apps/promote-app-version"
106458
+ },
106459
+ {
106460
+ srcPath: "/apps-release-manager-service-web/apps/release",
106461
+ destPath: "/apps/release"
106462
+ }
106463
+ ]
106236
106464
  };
106237
- return isPrefixed ? { log: prefixedLog } : { log };
106465
+ return resolveUrl(Object.assign(opts, { domainToMappings }));
106466
+ }
106467
+ function release(payload) {
106468
+ var _a = serializer(_releaseRequest, {}), toReq = _a.toJSON, fromReq = _a.fromJSON;
106469
+ var fromRes = serializer(_releaseResponse, {}).fromJSON;
106470
+ function __release(_a2) {
106471
+ var host = _a2.host;
106472
+ var serializedData = toReq(payload);
106473
+ var metadata = {
106474
+ entityFqdn: "wix.ctp.gradual_rollout.v1.baas_release",
106475
+ method: "POST",
106476
+ methodFqn: "com.wix.ctp.AppsReleaseManagerBassService.Release",
106477
+ migrationOptions: {
106478
+ optInTransformResponse: true
106479
+ },
106480
+ url: resolveComWixCtpAppsReleaseManagerBassServiceUrl({
106481
+ protoPath: "/apps/release/{appId}/{componentOverrideId}",
106482
+ data: serializedData,
106483
+ host
106484
+ }),
106485
+ data: serializedData,
106486
+ transformResponse: fromRes
106487
+ };
106488
+ return metadata;
106489
+ }
106490
+ __release.fromReq = fromReq;
106491
+ __release.__isAmbassador = true;
106492
+ return __release;
106238
106493
  }
106239
106494
 
106240
- // ../cli-astro-commands/src/components/DevCommand/hooks/useFetchDevMetadata.ts
106495
+ // ../arm-client/src/client.ts
106496
+ var import_variant = __toESM(require_lib(), 1);
106497
+
106498
+ // ../arm-client/src/isTrustedInternalErr.ts
106241
106499
  init_esm_shims();
106242
- function useFetchDevMetadata() {
106243
- const http = useHttpClient({ type: "standalone" });
106244
- return useAsyncCallback(async (_, serverLocalUrl) => {
106245
- const url = new URL("/_wix/dev-metadata.json", serverLocalUrl);
106246
- try {
106247
- const { data } = await http.get(url.toString());
106248
- return {
106249
- devMetadata: devMetadataSchema.parse(data),
106250
- serverLocalUrl
106251
- };
106252
- } catch {
106253
- return {
106254
- devMetadata: null,
106255
- serverLocalUrl
106256
- };
106500
+ function isTrustedInternalErr(e) {
106501
+ if (isHttpError(e)) {
106502
+ const appError = e.response?.data?.details?.applicationError;
106503
+ if (appError?.description) {
106504
+ let errDescription;
106505
+ try {
106506
+ errDescription = JSON.parse(appError.description);
106507
+ } catch {
106508
+ }
106509
+ return errDescription?.results?.some(
106510
+ (result) => result.error?.startsWith("scriptAsset is not supported")
106511
+ );
106257
106512
  }
106258
- });
106513
+ }
106514
+ return false;
106259
106515
  }
106260
106516
 
106261
- // ../cli-astro-commands/src/components/DevCommand/SiteDevFlow.tsx
106517
+ // ../arm-client/src/schemas.ts
106262
106518
  init_esm_shims();
106263
- var import_react6 = __toESM(require_react(), 1);
106264
- var import_variant4 = __toESM(require_lib(), 1);
106519
+ var promoteAppVersionFromDraftToProductionSchema = external_exports.object({
106520
+ fullVersion: external_exports.string()
106521
+ });
106522
+ var commitComponentOverrideSchema = external_exports.object({
106523
+ nextMajor: external_exports.string(),
106524
+ nextMinor: external_exports.string().optional()
106525
+ });
106526
+ var createAppReleaseSchema = external_exports.object({
106527
+ tag: external_exports.string()
106528
+ });
106529
+ var releaseArm2Schema = external_exports.object({
106530
+ releaseBaseUrl: external_exports.string()
106531
+ });
106265
106532
 
106266
- // ../cli-astro-commands/src/components/DevCommand/DevScreenBorder.tsx
106267
- init_esm_shims();
106268
- var import_react2 = __toESM(require_react(), 1);
106269
- var DevScreenBorder = ({ children }) => {
106270
- return /* @__PURE__ */ import_react2.default.createElement(
106271
- Box_default,
106272
- {
106273
- flexDirection: "column",
106274
- borderTop: true,
106275
- borderLeft: false,
106276
- borderBottom: false,
106277
- borderRight: false,
106278
- borderStyle: "round",
106279
- borderColor: "blueBright",
106280
- width: "95%"
106281
- },
106282
- children
106283
- );
106533
+ // ../arm-client/src/client.ts
106534
+ var { AppPermissionDenied } = CliErrorCode;
106535
+ var UpdateAppReleaseData = (0, import_variant.variant)({
106536
+ TagNotFound: (0, import_variant.fields)(),
106537
+ TagUpdated: {}
106538
+ });
106539
+ var ARMClient = class {
106540
+ constructor(httpClient) {
106541
+ this.httpClient = httpClient;
106542
+ const { minRetryTimeout } = getTestOverrides();
106543
+ this.retryOptions = {
106544
+ maxTimeout: 3 * 1e3,
106545
+ minTimeout: minRetryTimeout,
106546
+ retries: 3
106547
+ };
106548
+ }
106549
+ retryOptions;
106550
+ createComponents = async (appId, componentConfigs, projectId) => {
106551
+ try {
106552
+ await this.httpClient.request(
106553
+ createComponents({ appId, componentConfigs, projectId })
106554
+ );
106555
+ } catch (e) {
106556
+ if (isHttpError(e) && e.response?.status === 403) {
106557
+ throw new CliError({
106558
+ cause: e,
106559
+ code: AppPermissionDenied({ appId })
106560
+ });
106561
+ }
106562
+ throw new CliError({
106563
+ cause: e,
106564
+ code: CliErrorCode.FailedToCreateComponents()
106565
+ });
106566
+ }
106567
+ };
106568
+ createAppRelease = async (manifest, projectId) => {
106569
+ try {
106570
+ const { data } = await pRetry(
106571
+ () => this.httpClient.request(
106572
+ createAppRelease({
106573
+ appId: manifest.appId,
106574
+ componentConfigs: manifest.components,
106575
+ projectId
106576
+ })
106577
+ ),
106578
+ this.retryOptions
106579
+ );
106580
+ return createAppReleaseSchema.parse(data).tag;
106581
+ } catch (e) {
106582
+ if (isHttpError(e)) {
106583
+ if (e.response?.status === 403) {
106584
+ throw new CliError({
106585
+ cause: e,
106586
+ code: AppPermissionDenied({ appId: manifest.appId })
106587
+ });
106588
+ }
106589
+ if (e.response?.status === 400 && isHttpValidationError(e)) {
106590
+ throw new CliError({
106591
+ cause: e,
106592
+ code: CliErrorCode.AppReleaseConfigViolations({
106593
+ violations: e.response.data.details.validationError.fieldViolations
106594
+ })
106595
+ });
106596
+ }
106597
+ }
106598
+ if (isTrustedInternalErr(e)) {
106599
+ throw new CliError({
106600
+ cause: e,
106601
+ code: CliErrorCode.TrustedAppIsNotMarkedAsInternal()
106602
+ });
106603
+ }
106604
+ throw new CliError({
106605
+ cause: e,
106606
+ code: CliErrorCode.FailedToCreateAppRelease()
106607
+ });
106608
+ }
106609
+ };
106610
+ createLooseAppRelease = async (manifest, projectId) => {
106611
+ return this.createAppRelease(manifest, projectId);
106612
+ };
106613
+ updateAppRelease = async (manifest, tag) => {
106614
+ try {
106615
+ await pRetry(
106616
+ () => this.httpClient.request(
106617
+ updateAppRelease({
106618
+ appId: manifest.appId,
106619
+ componentConfigs: manifest.components,
106620
+ tag
106621
+ })
106622
+ ),
106623
+ this.retryOptions
106624
+ );
106625
+ return UpdateAppReleaseData.TagUpdated();
106626
+ } catch (e) {
106627
+ if (isHttpError(e)) {
106628
+ if (e.response?.status === 404) {
106629
+ return UpdateAppReleaseData.TagNotFound({ cause: e });
106630
+ }
106631
+ if (e.response?.status === 403) {
106632
+ throw new CliError({
106633
+ cause: e,
106634
+ code: AppPermissionDenied({ appId: manifest.appId })
106635
+ });
106636
+ }
106637
+ if (e.response?.status === 400 && isHttpValidationError(e)) {
106638
+ throw new CliError({
106639
+ cause: e,
106640
+ code: CliErrorCode.AppReleaseConfigViolations({
106641
+ violations: e.response.data.details.validationError.fieldViolations
106642
+ })
106643
+ });
106644
+ }
106645
+ }
106646
+ throw new CliError({
106647
+ cause: e,
106648
+ code: CliErrorCode.FailedToUpdateAppRelease()
106649
+ });
106650
+ }
106651
+ };
106652
+ updateLooseAppRelease = async (manifest, tag) => {
106653
+ return this.updateAppRelease(manifest, tag);
106654
+ };
106655
+ createDraftVersion = async (appId, tag) => {
106656
+ try {
106657
+ const { data } = await this.httpClient.request(
106658
+ commitComponentOverride({
106659
+ appId,
106660
+ componentOverrideId: tag
106661
+ })
106662
+ );
106663
+ return commitComponentOverrideSchema.parse(data);
106664
+ } catch (cause) {
106665
+ throw new CliError({
106666
+ cause,
106667
+ code: CliErrorCode.FailedToCreateDraftVersion()
106668
+ });
106669
+ }
106670
+ };
106671
+ releaseDraftVersion = async (appId, options) => {
106672
+ try {
106673
+ const { data } = await this.httpClient.request(
106674
+ promoteAppVersionFromDraftToProduction({
106675
+ appId,
106676
+ createNewMajor: options.createNewMajor,
106677
+ latestMajor: options.latestMajor,
106678
+ notes: options.notes
106679
+ })
106680
+ );
106681
+ const { fullVersion } = promoteAppVersionFromDraftToProductionSchema.parse(data);
106682
+ return { releasedVersion: fullVersion };
106683
+ } catch (cause) {
106684
+ throw new CliError({
106685
+ cause,
106686
+ code: CliErrorCode.FailedToReleaseDraftVersion()
106687
+ });
106688
+ }
106689
+ };
106690
+ release = async (appId, componentOverrideId, options) => {
106691
+ try {
106692
+ const { comment, createMinorVersion } = options;
106693
+ const { data } = await this.httpClient.request(
106694
+ release({
106695
+ appId,
106696
+ componentOverrideId,
106697
+ createMinorVersion,
106698
+ notes: comment
106699
+ })
106700
+ );
106701
+ return releaseArm2Schema.parse(data).releaseBaseUrl;
106702
+ } catch (e) {
106703
+ throw new CliError({
106704
+ cause: e,
106705
+ code: CliErrorCode.FailedToReleaseHeadlessProject()
106706
+ });
106707
+ }
106708
+ };
106284
106709
  };
106285
106710
 
106286
- // ../cli-astro-commands/src/components/DevCommand/DevCenterUpdater.tsx
106711
+ // ../arm-client/src/useARMClient.ts
106712
+ function useARMClient() {
106713
+ const httpClient = useHttpClient({ type: "backoffice" });
106714
+ const client = (0, import_react.useMemo)(() => new ARMClient(httpClient), [httpClient]);
106715
+ return usePanoramaMethodLogger(client);
106716
+ }
106717
+
106718
+ // ../arm-client/src/index.ts
106287
106719
  init_esm_shims();
106288
- var import_react5 = __toESM(require_react(), 1);
106289
- import { isDeepStrictEqual } from "node:util";
106290
- var import_variant3 = __toESM(require_lib(), 1);
106291
106720
 
106292
- // ../cli-astro-commands/src/files/app.config.ts
106721
+ // ../cli-astro-commands/src/site/SiteProvider.tsx
106293
106722
  init_esm_shims();
106723
+ var import_react13 = __toESM(require_react(), 1);
106724
+ var import_variant10 = __toESM(require_lib(), 1);
106294
106725
 
106295
106726
  // ../cli-app-definitions/src/index.ts
106296
106727
  init_esm_shims();
106297
- var import_variant = __toESM(require_lib(), 1);
106728
+ var import_variant2 = __toESM(require_lib(), 1);
106298
106729
  import { join } from "node:path";
106299
106730
  var import_monitoring_buildtime = __toESM(require_build(), 1);
106300
106731
  var GIT_IGNORED_DIR = ".wix";
@@ -106578,7 +107009,7 @@ var embeddedScriptConfigSchema = external_exports.object({
106578
107009
  "An enum indicating where in the page's DOM the HTML code will be injected."
106579
107010
  )
106580
107011
  }).strict();
106581
- var PlatformType = (0, import_variant.variant)({
107012
+ var PlatformType2 = (0, import_variant2.variant)({
106582
107013
  Site: {},
106583
107014
  Editor: {},
106584
107015
  Dashboard: {},
@@ -106842,300 +107273,6 @@ var siteComponentPanelConfigSchema = external_exports.object({
106842
107273
  panelMode: external_exports.enum([PanelMode.overlay]).optional()
106843
107274
  }).strict();
106844
107275
 
106845
- // ../cli-astro-commands/src/files/app.config.ts
106846
- async function readAppConfig(projectFolder, writeDebugLog) {
106847
- const configPath = getAppConfigPath(projectFolder);
106848
- const isConfigExist = await pathExists(configPath);
106849
- if (!isConfigExist) {
106850
- return null;
106851
- }
106852
- try {
106853
- const json = await readJson(configPath);
106854
- const appConfig = await appConfigSchema.safeParseAsync(json);
106855
- if (!appConfig.success) {
106856
- return null;
106857
- }
106858
- return appConfig.data;
106859
- } catch (e) {
106860
- writeDebugLog?.(e);
106861
- return null;
106862
- }
106863
- }
106864
- async function saveAppConfig(projectFolder, config) {
106865
- const currentConfig = await readAppConfig(projectFolder) ?? {};
106866
- const newConfig = {
106867
- ...currentConfig,
106868
- ...config
106869
- };
106870
- await writeJson(getAppConfigPath(projectFolder), newConfig);
106871
- }
106872
-
106873
- // ../cli-astro-commands/src/components/DevCommand/TunnelingConsent.tsx
106874
- init_esm_shims();
106875
- var import_react3 = __toESM(require_react(), 1);
106876
- var import_variant2 = __toESM(require_lib(), 1);
106877
- var TunnelingConsent = ({ required, children }) => {
106878
- const exit = useExit();
106879
- const [approved, setApproved] = (0, import_react3.useState)();
106880
- const { status } = useAsync(async () => {
106881
- const config = await readUserConfig();
106882
- if (config.tunneling) {
106883
- setApproved(true);
106884
- }
106885
- return config;
106886
- }, []);
106887
- if (!required || approved) {
106888
- return children;
106889
- }
106890
- return /* @__PURE__ */ import_react3.default.createElement(import_react3.default.Fragment, null, (0, import_variant2.match)(status, {
106891
- Success: () => /* @__PURE__ */ import_react3.default.createElement(
106892
- ConfirmInput,
106893
- {
106894
- label: "To proceed, we'll set up a secure tunnel from your machine for development purposes",
106895
- initialValue: true,
106896
- onSubmit: async (approved2) => {
106897
- setApproved(approved2);
106898
- await updateUserConfig({ tunneling: approved2 });
106899
- if (!approved2) {
106900
- exit();
106901
- }
106902
- }
106903
- }
106904
- ),
106905
- Error: () => null,
106906
- Loading: () => null
106907
- }), approved === false && /* @__PURE__ */ import_react3.default.createElement(Text, { skin: "error" }, "Operation aborted. Tunneling is necessary to run your application."));
106908
- };
106909
-
106910
- // ../cli-astro-commands/src/components/DevCommand/hooks/useFetchAppManifest.ts
106911
- init_esm_shims();
106912
- var import_react4 = __toESM(require_react(), 1);
106913
-
106914
- // ../cli-astro-commands/src/components/DevCommand/utils/isTunnelRequired.ts
106915
- init_esm_shims();
106916
- function isTunnelRequired(appManifest) {
106917
- for (const extension of appManifest.components) {
106918
- const knownAppManifest = parseKnownExtensionManifest(extension);
106919
- if (knownAppManifest != null && knownAppManifest.compType === ComponentType.WEBHOOK) {
106920
- return !URL.canParse(knownAppManifest.compData.webhook.callbackUrl);
106921
- }
106922
- }
106923
- return false;
106924
- }
106925
- function parseKnownExtensionManifest(extensionManifest) {
106926
- const appManifestResult = looseComponentSchema.safeParse(extensionManifest);
106927
- if (appManifestResult.error) {
106928
- return null;
106929
- }
106930
- return appManifestResult.data;
106931
- }
106932
-
106933
- // ../cli-astro-commands/src/components/DevCommand/hooks/useFetchAppManifest.ts
106934
- function useFetchAppManifest() {
106935
- const http = useHttpClient({ type: "standalone" });
106936
- return (0, import_react4.useCallback)(
106937
- async (serverLocalUrl, devMetadata, baseUrl, tunnelUrl) => {
106938
- const url = new URL("/_wix/app-manifest.json", serverLocalUrl);
106939
- const { data: text } = await http.get(url.toString(), {
106940
- responseType: "text",
106941
- transitional: {
106942
- silentJSONParsing: true,
106943
- forcedJSONParsing: false,
106944
- clarifyTimeoutError: false
106945
- },
106946
- disableWixHeaders: true
106947
- });
106948
- if (devMetadata != null) {
106949
- const placeholders = /* @__PURE__ */ new Map();
106950
- placeholders.set(devMetadata.staticsUrlPlaceholder, baseUrl);
106951
- placeholders.set(devMetadata.serverUrlPlaceholder, tunnelUrl);
106952
- return {
106953
- manifest: parseLooseAppManifest(text, placeholders),
106954
- isTunnelRequired: text.includes(devMetadata.serverUrlPlaceholder)
106955
- };
106956
- }
106957
- const manifestV1 = parseLooseAppManifest(text);
106958
- return {
106959
- manifest: manifestV1,
106960
- isTunnelRequired: isTunnelRequired(manifestV1)
106961
- };
106962
- },
106963
- [http]
106964
- );
106965
- }
106966
-
106967
- // ../cli-astro-commands/src/components/DevCommand/DevCenterUpdater.tsx
106968
- var DevCenterUpdateResult = (0, import_variant3.variant)({
106969
- Changed: (0, import_variant3.fields)(),
106970
- Unchanged: {}
106971
- });
106972
- var DevCenterUpdater = ({ siteId, serverLocalUrl, serverExposedUrl, devMetadata }) => {
106973
- const [devArmTag, setDevArmTag] = (0, import_react5.useState)("");
106974
- const [manifest, setManifest] = (0, import_react5.useState)(null);
106975
- const writeToDebugLog = useDebugLog();
106976
- const {
106977
- model: {
106978
- config: { appId },
106979
- projectFolder
106980
- }
106981
- } = useProjectModel();
106982
- const logger = (0, import_react5.useMemo)(() => createAstroLogger(), []);
106983
- const { updateManifest } = useUpdateManifest();
106984
- const arm = useARMClient();
106985
- const updateDeploymentTopology = useUpdateDeploymentTopology(siteId);
106986
- const openTunnel = useTunnel();
106987
- const tunnelUrl = (0, import_react5.useRef)();
106988
- const [tunnelRequired, setTunnelRequired] = (0, import_react5.useState)(false);
106989
- const fetchAppManifest = useFetchAppManifest();
106990
- const updateDevCenter = (0, import_react5.useCallback)(async () => {
106991
- const baseUrl = serverExposedUrl ?? serverLocalUrl;
106992
- const { manifest: latestManifest, isTunnelRequired: isTunnelRequired2 } = await fetchAppManifest(
106993
- serverLocalUrl,
106994
- devMetadata,
106995
- baseUrl,
106996
- tunnelUrl.current ?? baseUrl
106997
- );
106998
- if (isDeepStrictEqual(manifest, latestManifest)) {
106999
- return DevCenterUpdateResult.Unchanged();
107000
- }
107001
- if (!serverExposedUrl && !tunnelUrl.current && isTunnelRequired2) {
107002
- const config = await readUserConfig();
107003
- if (!config.tunneling) {
107004
- setTunnelRequired(true);
107005
- return DevCenterUpdateResult.Unchanged();
107006
- }
107007
- const serverLocalPort = parseInt(new URL(serverLocalUrl).port, 10);
107008
- const tunnel = await openTunnel(serverLocalPort);
107009
- tunnelUrl.current = tunnel.url;
107010
- return DevCenterUpdateResult.Unchanged();
107011
- }
107012
- const appConfig = await readAppConfig(projectFolder);
107013
- let updatedDevArmTag = appConfig?.devArmTag;
107014
- if (!updatedDevArmTag) {
107015
- updatedDevArmTag = await arm.createLooseAppRelease(
107016
- updateManifest(latestManifest, baseUrl, tunnelUrl.current),
107017
- appId
107018
- );
107019
- } else {
107020
- const updateState = await arm.updateLooseAppRelease(
107021
- updateManifest(latestManifest, baseUrl, tunnelUrl.current),
107022
- updatedDevArmTag
107023
- );
107024
- if (!(0, import_variant3.isType)(updateState, "TagUpdated")) {
107025
- updatedDevArmTag = await arm.createLooseAppRelease(
107026
- updateManifest(latestManifest, baseUrl, tunnelUrl.current),
107027
- appId
107028
- );
107029
- }
107030
- }
107031
- if (updatedDevArmTag !== appConfig?.devArmTag) {
107032
- await saveAppConfig(projectFolder, { devArmTag: updatedDevArmTag });
107033
- }
107034
- setManifest(latestManifest);
107035
- setDevArmTag(updatedDevArmTag);
107036
- await updateDeploymentTopology.execute({
107037
- serverUrl: baseUrl,
107038
- armTag: updatedDevArmTag,
107039
- environment: "development"
107040
- });
107041
- const armTagChanged = !!appConfig?.devArmTag && updatedDevArmTag !== appConfig.devArmTag;
107042
- return DevCenterUpdateResult.Changed({ armTagChanged });
107043
- }, [
107044
- fetchAppManifest,
107045
- updateManifest,
107046
- serverLocalUrl,
107047
- serverExposedUrl,
107048
- arm,
107049
- manifest,
107050
- projectFolder,
107051
- appId,
107052
- updateDeploymentTopology,
107053
- openTunnel,
107054
- devMetadata
107055
- ]);
107056
- const [timer, setTimer] = (0, import_react5.useState)(Date.now());
107057
- (0, import_react5.useEffect)(() => {
107058
- let disposed = false;
107059
- void updateDevCenter().then((result) => {
107060
- if ((0, import_variant3.isType)(result, "Changed")) {
107061
- logger.log(
107062
- "App Manifest updated. Refresh existing browser tabs to view the latest changes."
107063
- );
107064
- }
107065
- }).catch((error) => {
107066
- logger.log("Failed to update App Manifest");
107067
- logger.log(`${error}`);
107068
- writeToDebugLog(error);
107069
- }).then(() => {
107070
- if (!disposed) {
107071
- setTimeout(() => setTimer(Date.now()), 1e3);
107072
- }
107073
- });
107074
- return () => {
107075
- disposed = true;
107076
- };
107077
- }, [timer]);
107078
- return /* @__PURE__ */ import_react5.default.createElement(Box_default, { rowGap: 1, marginY: 1, flexDirection: "column" }, /* @__PURE__ */ import_react5.default.createElement(TunnelingConsent, { required: tunnelRequired }, /* @__PURE__ */ import_react5.default.createElement(Text, null, "Open the preview on:"), /* @__PURE__ */ import_react5.default.createElement(Box_default, { paddingLeft: 2, flexDirection: "column" }, /* @__PURE__ */ import_react5.default.createElement(PlatformLink, { url: serverLocalUrl, label: "Site" }), devArmTag ? /* @__PURE__ */ import_react5.default.createElement(
107079
- PlatformLink,
107080
- {
107081
- url: `https://manage.wix.com/dashboard/${siteId}?apps-override=${devArmTag}`,
107082
- label: "Dashboard"
107083
- }
107084
- ) : /* @__PURE__ */ import_react5.default.createElement(Spinner, { text: "Preparing your dashboard..." }))));
107085
- };
107086
-
107087
- // ../cli-astro-commands/src/components/DevCommand/SiteDevFlow.tsx
107088
- var SiteDevFlow = ({
107089
- siteId,
107090
- devMetadataStatus,
107091
- serverExposedUrl
107092
- }) => {
107093
- return /* @__PURE__ */ import_react6.default.createElement(SiteAuthProvider, { siteId }, (0, import_variant4.match)(devMetadataStatus, {
107094
- NotRequested: () => /* @__PURE__ */ import_react6.default.createElement(Spinner, { text: "Starting dev environment..." }),
107095
- Error: () => null,
107096
- Loading: () => /* @__PURE__ */ import_react6.default.createElement(Spinner, { text: "Checking dev environment settings..." }),
107097
- Success: ({ result: { devMetadata, serverLocalUrl } }) => /* @__PURE__ */ import_react6.default.createElement(DevScreenBorder, null, /* @__PURE__ */ import_react6.default.createElement(Text, null, "Development environment ready"), /* @__PURE__ */ import_react6.default.createElement(
107098
- DevCenterUpdater,
107099
- {
107100
- siteId,
107101
- devMetadata,
107102
- serverLocalUrl,
107103
- serverExposedUrl
107104
- }
107105
- ))
107106
- }));
107107
- };
107108
-
107109
- // ../cli-astro-commands/src/components/DevCommand/AppDevFlow.tsx
107110
- init_esm_shims();
107111
- var import_react26 = __toESM(require_react(), 1);
107112
- var import_variant16 = __toESM(require_lib(), 1);
107113
-
107114
- // ../cli-astro-commands/src/components/DevCommand/app-flow/AppDev.tsx
107115
- init_esm_shims();
107116
- var import_react25 = __toESM(require_react(), 1);
107117
- var import_variant15 = __toESM(require_lib(), 1);
107118
-
107119
- // ../cli-astro-commands/src/components/DevCommand/app-flow/screen-state.ts
107120
- init_esm_shims();
107121
- var import_variant5 = __toESM(require_lib(), 1);
107122
- var ScreenState = (0, import_variant5.variant)({
107123
- Home: {},
107124
- SiteSelector: {}
107125
- });
107126
-
107127
- // ../cli-astro-commands/src/components/DevCommand/app-flow/SiteSelectorScreen.tsx
107128
- init_esm_shims();
107129
- var import_react22 = __toESM(require_react(), 1);
107130
-
107131
- // ../cli-site-selector/src/index.ts
107132
- init_esm_shims();
107133
-
107134
- // ../cli-site-selector/src/SiteSelector.tsx
107135
- init_esm_shims();
107136
- var import_react15 = __toESM(require_react(), 1);
107137
- var import_variant10 = __toESM(require_lib(), 1);
107138
-
107139
107276
  // ../site-list-client/src/index.ts
107140
107277
  init_esm_shims();
107141
107278
 
@@ -107328,12 +107465,20 @@ var SiteListClient = class {
107328
107465
  });
107329
107466
  }
107330
107467
  };
107331
- getSite = async (id) => {
107468
+ getSite = async (id, inclHeadless) => {
107469
+ const queryPayload = {
107470
+ query: {
107471
+ filter: {
107472
+ id: { $in: [id] },
107473
+ ...inclHeadless ? {
107474
+ namespace: { $in: ["WIX", "HEADLESS"] }
107475
+ } : {}
107476
+ }
107477
+ }
107478
+ };
107332
107479
  try {
107333
107480
  const { data } = await pRetry(
107334
- () => this.httpClient.request(
107335
- querySites({ query: { filter: { id: { $in: [id] } } } })
107336
- ),
107481
+ () => this.httpClient.request(querySites(queryPayload)),
107337
107482
  this.retryOptions
107338
107483
  );
107339
107484
  const { sites } = querySitesSchema.parse(data);
@@ -107350,21 +107495,63 @@ var SiteListClient = class {
107350
107495
 
107351
107496
  // ../site-list-client/src/useSiteListClient.ts
107352
107497
  init_esm_shims();
107353
- var import_react7 = __toESM(require_react(), 1);
107498
+ var import_react2 = __toESM(require_react(), 1);
107354
107499
  function useSiteListClient() {
107355
107500
  const httpClient = useHttpClient({ type: "backoffice" });
107356
- const client = (0, import_react7.useMemo)(() => new SiteListClient(httpClient), [httpClient]);
107501
+ const client = (0, import_react2.useMemo)(() => new SiteListClient(httpClient), [httpClient]);
107357
107502
  return usePanoramaMethodLogger(client);
107358
107503
  }
107359
107504
 
107505
+ // ../cli-astro-commands/src/files/app.config.ts
107506
+ init_esm_shims();
107507
+ async function readAppConfig(projectFolder, writeDebugLog) {
107508
+ const configPath = getAppConfigPath(projectFolder);
107509
+ const isConfigExist = await pathExists(configPath);
107510
+ if (!isConfigExist) {
107511
+ return null;
107512
+ }
107513
+ try {
107514
+ const json = await readJson(configPath);
107515
+ const appConfig = await appConfigSchema.safeParseAsync(json);
107516
+ if (!appConfig.success) {
107517
+ return null;
107518
+ }
107519
+ return appConfig.data;
107520
+ } catch (e) {
107521
+ writeDebugLog?.(e);
107522
+ return null;
107523
+ }
107524
+ }
107525
+ async function saveAppConfig(projectFolder, config) {
107526
+ const currentConfig = await readAppConfig(projectFolder) ?? {};
107527
+ const newConfig = {
107528
+ ...currentConfig,
107529
+ ...config
107530
+ };
107531
+ await writeJson(getAppConfigPath(projectFolder), newConfig);
107532
+ }
107533
+
107534
+ // ../cli-astro-commands/src/site/ResolveSite.tsx
107535
+ init_esm_shims();
107536
+ var import_react11 = __toESM(require_react(), 1);
107537
+ var import_variant8 = __toESM(require_lib(), 1);
107538
+
107539
+ // ../cli-site-selector/src/index.ts
107540
+ init_esm_shims();
107541
+
107542
+ // ../cli-site-selector/src/SiteSelector.tsx
107543
+ init_esm_shims();
107544
+ var import_react10 = __toESM(require_react(), 1);
107545
+ var import_variant7 = __toESM(require_lib(), 1);
107546
+
107360
107547
  // ../cli-site-selector/src/SiteTypeSelect.tsx
107361
107548
  init_esm_shims();
107362
- var import_react9 = __toESM(require_react(), 1);
107363
- var import_variant6 = __toESM(require_lib(), 1);
107549
+ var import_react4 = __toESM(require_react(), 1);
107550
+ var import_variant3 = __toESM(require_lib(), 1);
107364
107551
 
107365
107552
  // ../cli-site-selector/src/bi.ts
107366
107553
  init_esm_shims();
107367
- var import_react8 = __toESM(require_react(), 1);
107554
+ var import_react3 = __toESM(require_react(), 1);
107368
107555
  function siteSelectorBiEvents(biLogger) {
107369
107556
  return {
107370
107557
  cliAction: ({
@@ -107399,7 +107586,7 @@ function siteSelectorBiEvents(biLogger) {
107399
107586
  }
107400
107587
  function useSiteSelectorBi() {
107401
107588
  const biLogger = useBiLogger();
107402
- return (0, import_react8.useMemo)(() => siteSelectorBiEvents(biLogger), [biLogger]);
107589
+ return (0, import_react3.useMemo)(() => siteSelectorBiEvents(biLogger), [biLogger]);
107403
107590
  }
107404
107591
 
107405
107592
  // ../cli-site-selector/src/SiteTypeSelect.tsx
@@ -107419,13 +107606,13 @@ var SiteTypeSelect = ({ onSubmit, onError, sites }) => {
107419
107606
  });
107420
107607
  onSubmit(option.value);
107421
107608
  };
107422
- return (0, import_variant6.match)(status, {
107609
+ return (0, import_variant3.match)(status, {
107423
107610
  Error: () => null,
107424
- Loading: () => /* @__PURE__ */ import_react9.default.createElement(Spinner, { text: t("general.loading") }),
107611
+ Loading: () => /* @__PURE__ */ import_react4.default.createElement(Spinner, { text: t("general.loading") }),
107425
107612
  Success: ({ result: [devSitesCount, devSitesLimit] }) => {
107426
107613
  const isDevSitesLimitReached = devSitesCount >= devSitesLimit;
107427
107614
  const userHasNoSites = sites.length === 0;
107428
- return /* @__PURE__ */ import_react9.default.createElement(
107615
+ return /* @__PURE__ */ import_react4.default.createElement(
107429
107616
  SelectInput,
107430
107617
  {
107431
107618
  label: t("site_type_select.label"),
@@ -107456,17 +107643,17 @@ var SiteTypeSelect = ({ onSubmit, onError, sites }) => {
107456
107643
 
107457
107644
  // ../cli-site-selector/src/CreateDevSite.tsx
107458
107645
  init_esm_shims();
107459
- var import_react12 = __toESM(require_react(), 1);
107460
- var import_variant8 = __toESM(require_lib(), 1);
107646
+ var import_react7 = __toESM(require_react(), 1);
107647
+ var import_variant5 = __toESM(require_lib(), 1);
107461
107648
 
107462
107649
  // ../cli-site-selector/src/WaitForAppToBeInstalled.tsx
107463
107650
  init_esm_shims();
107464
- var import_react11 = __toESM(require_react(), 1);
107465
- var import_variant7 = __toESM(require_lib(), 1);
107651
+ var import_react6 = __toESM(require_react(), 1);
107652
+ var import_variant4 = __toESM(require_lib(), 1);
107466
107653
 
107467
107654
  // ../cli-site-selector/src/OpenBrowser.tsx
107468
107655
  init_esm_shims();
107469
- var import_react10 = __toESM(require_react(), 1);
107656
+ var import_react5 = __toESM(require_react(), 1);
107470
107657
  var OpenBrowser = ({ siteId, appId }) => {
107471
107658
  const { t } = useTranslation();
107472
107659
  const bi = useSiteSelectorBi();
@@ -107482,17 +107669,17 @@ var OpenBrowser = ({ siteId, appId }) => {
107482
107669
  );
107483
107670
  }
107484
107671
  });
107485
- return /* @__PURE__ */ import_react10.default.createElement(import_react10.default.Fragment, null, /* @__PURE__ */ import_react10.default.createElement(Trans, { i18nKey: "install_app_on_site.warning" }), /* @__PURE__ */ import_react10.default.createElement(
107672
+ return /* @__PURE__ */ import_react5.default.createElement(import_react5.default.Fragment, null, /* @__PURE__ */ import_react5.default.createElement(Trans, { i18nKey: "install_app_on_site.warning" }), /* @__PURE__ */ import_react5.default.createElement(
107486
107673
  Trans,
107487
107674
  {
107488
107675
  i18nKey: "install_app_on_site.warning.instructions",
107489
- components: [/* @__PURE__ */ import_react10.default.createElement(Key, { value: "Enter" })]
107676
+ components: [/* @__PURE__ */ import_react5.default.createElement(Key, { value: "Enter" })]
107490
107677
  }
107491
107678
  ));
107492
107679
  };
107493
107680
 
107494
107681
  // ../cli-site-selector/src/WaitForAppToBeInstalled.tsx
107495
- var AppInstallData = (0, import_variant7.variant)({
107682
+ var AppInstallData = (0, import_variant4.variant)({
107496
107683
  Success: {},
107497
107684
  Canceled: {}
107498
107685
  });
@@ -107536,16 +107723,16 @@ var WaitForAppToBeInstalled = ({
107536
107723
  {
107537
107724
  onError,
107538
107725
  onSuccess: (result) => {
107539
- if ((0, import_variant7.isType)(result, AppInstallData.Success)) {
107726
+ if ((0, import_variant4.isType)(result, AppInstallData.Success)) {
107540
107727
  onSubmit();
107541
107728
  }
107542
107729
  }
107543
107730
  }
107544
107731
  );
107545
- return (0, import_variant7.match)(status, {
107732
+ return (0, import_variant4.match)(status, {
107546
107733
  Error: () => null,
107547
- Loading: () => /* @__PURE__ */ import_react11.default.createElement(OpenBrowser, { siteId: site.id, appId }),
107548
- Success: () => /* @__PURE__ */ import_react11.default.createElement(Alert, { type: "success" }, /* @__PURE__ */ import_react11.default.createElement(Badge, { skin: "success" }, /* @__PURE__ */ import_react11.default.createElement(Trans, { i18nKey: "general.success" })), " ", /* @__PURE__ */ import_react11.default.createElement(Trans, { i18nKey: "install_app_on_site.finished_successfully" }))
107734
+ Loading: () => /* @__PURE__ */ import_react6.default.createElement(OpenBrowser, { siteId: site.id, appId }),
107735
+ Success: () => /* @__PURE__ */ import_react6.default.createElement(Alert, { type: "success" }, /* @__PURE__ */ import_react6.default.createElement(Badge, { skin: "success" }, /* @__PURE__ */ import_react6.default.createElement(Trans, { i18nKey: "general.success" })), " ", /* @__PURE__ */ import_react6.default.createElement(Trans, { i18nKey: "install_app_on_site.finished_successfully" }))
107549
107736
  });
107550
107737
  };
107551
107738
 
@@ -107557,18 +107744,18 @@ var CreateDevSite = ({
107557
107744
  onError
107558
107745
  }) => {
107559
107746
  const { t } = useTranslation();
107560
- return (0, import_variant8.match)(status, {
107747
+ return (0, import_variant5.match)(status, {
107561
107748
  NotRequested: () => null,
107562
107749
  Error: () => null,
107563
- Loading: () => /* @__PURE__ */ import_react12.default.createElement(Spinner, { text: t("create_dev_site.loading") }),
107564
- Success: ({ result }) => /* @__PURE__ */ import_react12.default.createElement(import_react12.default.Fragment, null, /* @__PURE__ */ import_react12.default.createElement(
107750
+ Loading: () => /* @__PURE__ */ import_react7.default.createElement(Spinner, { text: t("create_dev_site.loading") }),
107751
+ Success: ({ result }) => /* @__PURE__ */ import_react7.default.createElement(import_react7.default.Fragment, null, /* @__PURE__ */ import_react7.default.createElement(
107565
107752
  Trans,
107566
107753
  {
107567
107754
  i18nKey: "create_dev_site.success",
107568
- components: [/* @__PURE__ */ import_react12.default.createElement(Text, { skin: "success", bold: true })],
107755
+ components: [/* @__PURE__ */ import_react7.default.createElement(Text, { skin: "success", bold: true })],
107569
107756
  values: { name: result.displayName }
107570
107757
  }
107571
- ), /* @__PURE__ */ import_react12.default.createElement(SiteAuthProvider, { siteId: result.id }, /* @__PURE__ */ import_react12.default.createElement(
107758
+ ), /* @__PURE__ */ import_react7.default.createElement(SiteAuthProvider, { siteId: result.id }, /* @__PURE__ */ import_react7.default.createElement(
107572
107759
  WaitForAppToBeInstalled,
107573
107760
  {
107574
107761
  appId,
@@ -107582,16 +107769,16 @@ var CreateDevSite = ({
107582
107769
 
107583
107770
  // ../cli-site-selector/src/SelectExistingSite.tsx
107584
107771
  init_esm_shims();
107585
- var import_react14 = __toESM(require_react(), 1);
107586
- var import_variant9 = __toESM(require_lib(), 1);
107772
+ var import_react9 = __toESM(require_react(), 1);
107773
+ var import_variant6 = __toESM(require_lib(), 1);
107587
107774
 
107588
107775
  // ../cli-site-selector/src/SiteListSelect.tsx
107589
107776
  init_esm_shims();
107590
- var import_react13 = __toESM(require_react(), 1);
107777
+ var import_react8 = __toESM(require_react(), 1);
107591
107778
  var SiteListSelect = ({ onSubmit, sites }) => {
107592
107779
  const { t } = useTranslation();
107593
107780
  const bi = useSiteSelectorBi();
107594
- const handleSubmit = (0, import_react13.useCallback)(
107781
+ const handleSubmit = (0, import_react8.useCallback)(
107595
107782
  (option) => {
107596
107783
  bi.cliFlowStepAnswered({
107597
107784
  question: t("site_list_select.label"),
@@ -107601,7 +107788,7 @@ var SiteListSelect = ({ onSubmit, sites }) => {
107601
107788
  },
107602
107789
  [bi, onSubmit, t]
107603
107790
  );
107604
- return /* @__PURE__ */ import_react13.default.createElement(
107791
+ return /* @__PURE__ */ import_react8.default.createElement(
107605
107792
  SelectInput,
107606
107793
  {
107607
107794
  label: t("site_list_select.label"),
@@ -107628,14 +107815,14 @@ var CheckAppInstalledOnSite = ({ appId, site, onSubmit, onError }) => {
107628
107815
  }
107629
107816
  }
107630
107817
  });
107631
- return (0, import_variant9.match)(status, {
107818
+ return (0, import_variant6.match)(status, {
107632
107819
  Error: () => null,
107633
- Loading: () => /* @__PURE__ */ import_react14.default.createElement(Spinner, { text: t("general.loading") }),
107820
+ Loading: () => /* @__PURE__ */ import_react9.default.createElement(Spinner, { text: t("general.loading") }),
107634
107821
  Success: ({ result: isInstalled }) => {
107635
107822
  if (isInstalled) {
107636
107823
  return null;
107637
107824
  }
107638
- return /* @__PURE__ */ import_react14.default.createElement(
107825
+ return /* @__PURE__ */ import_react9.default.createElement(
107639
107826
  WaitForAppToBeInstalled,
107640
107827
  {
107641
107828
  appId,
@@ -107653,16 +107840,16 @@ var SelectExistingSite = ({
107653
107840
  onSubmit,
107654
107841
  onError
107655
107842
  }) => {
107656
- const [siteToInstallAppOn, setSiteToInstallAppOn] = (0, import_react14.useState)(
107843
+ const [siteToInstallAppOn, setSiteToInstallAppOn] = (0, import_react9.useState)(
107657
107844
  null
107658
107845
  );
107659
- return /* @__PURE__ */ import_react14.default.createElement(import_react14.default.Fragment, null, /* @__PURE__ */ import_react14.default.createElement(
107846
+ return /* @__PURE__ */ import_react9.default.createElement(import_react9.default.Fragment, null, /* @__PURE__ */ import_react9.default.createElement(
107660
107847
  SiteListSelect,
107661
107848
  {
107662
107849
  onSubmit: (site) => setSiteToInstallAppOn(site),
107663
107850
  sites
107664
107851
  }
107665
- ), siteToInstallAppOn && /* @__PURE__ */ import_react14.default.createElement(SiteAuthProvider, { siteId: siteToInstallAppOn.id }, /* @__PURE__ */ import_react14.default.createElement(
107852
+ ), siteToInstallAppOn && /* @__PURE__ */ import_react9.default.createElement(SiteAuthProvider, { siteId: siteToInstallAppOn.id }, /* @__PURE__ */ import_react9.default.createElement(
107666
107853
  CheckAppInstalledOnSite,
107667
107854
  {
107668
107855
  appId,
@@ -107697,7 +107884,7 @@ var SiteSelector = ({
107697
107884
  onSubmit,
107698
107885
  onError
107699
107886
  }) => {
107700
- const [siteType, setSiteType] = (0, import_react15.useState)(null);
107887
+ const [siteType, setSiteType] = (0, import_react10.useState)(null);
107701
107888
  const { createDevSite } = useDevCenterClient();
107702
107889
  const siteListClient = useSiteListClient();
107703
107890
  const { status } = useAsync(
@@ -107722,17 +107909,17 @@ var SiteSelector = ({
107722
107909
  void createSite.execute();
107723
107910
  }
107724
107911
  }
107725
- return /* @__PURE__ */ import_react15.default.createElement(BiProvider, { value: biLogger }, /* @__PURE__ */ import_react15.default.createElement(I18nProvider, { messages: messages_default }, (0, import_variant10.match)(status, {
107912
+ return /* @__PURE__ */ import_react10.default.createElement(BiProvider, { value: biLogger }, /* @__PURE__ */ import_react10.default.createElement(I18nProvider, { messages: messages_default }, (0, import_variant7.match)(status, {
107726
107913
  Error: () => null,
107727
- Loading: () => /* @__PURE__ */ import_react15.default.createElement(Spinner, { text: /* @__PURE__ */ import_react15.default.createElement(Trans, { i18nKey: "general.loading" }) }),
107728
- Success: ({ result: sites }) => /* @__PURE__ */ import_react15.default.createElement(import_react15.default.Fragment, null, /* @__PURE__ */ import_react15.default.createElement(
107914
+ Loading: () => /* @__PURE__ */ import_react10.default.createElement(Spinner, { text: /* @__PURE__ */ import_react10.default.createElement(Trans, { i18nKey: "general.loading" }) }),
107915
+ Success: ({ result: sites }) => /* @__PURE__ */ import_react10.default.createElement(import_react10.default.Fragment, null, /* @__PURE__ */ import_react10.default.createElement(
107729
107916
  SiteTypeSelect,
107730
107917
  {
107731
107918
  onSubmit: handleSelectSiteType,
107732
107919
  onError,
107733
107920
  sites
107734
107921
  }
107735
- ), siteType === "create-dev-site" && /* @__PURE__ */ import_react15.default.createElement(
107922
+ ), siteType === "create-dev-site" && /* @__PURE__ */ import_react10.default.createElement(
107736
107923
  CreateDevSite,
107737
107924
  {
107738
107925
  status: createSite.status,
@@ -107740,7 +107927,7 @@ var SiteSelector = ({
107740
107927
  onSubmit,
107741
107928
  onError
107742
107929
  }
107743
- ), siteType === "select-existing-site" && /* @__PURE__ */ import_react15.default.createElement(
107930
+ ), siteType === "select-existing-site" && /* @__PURE__ */ import_react10.default.createElement(
107744
107931
  SelectExistingSite,
107745
107932
  {
107746
107933
  sites,
@@ -107752,28 +107939,17 @@ var SiteSelector = ({
107752
107939
  })));
107753
107940
  };
107754
107941
 
107755
- // ../cli-astro-commands/src/site/index.ts
107756
- init_esm_shims();
107757
-
107758
- // ../cli-astro-commands/src/site/SiteProvider.tsx
107759
- init_esm_shims();
107760
- var import_react18 = __toESM(require_react(), 1);
107761
- var import_variant13 = __toESM(require_lib(), 1);
107762
-
107763
107942
  // ../cli-astro-commands/src/site/ResolveSite.tsx
107764
- init_esm_shims();
107765
- var import_react16 = __toESM(require_react(), 1);
107766
- var import_variant11 = __toESM(require_lib(), 1);
107767
107943
  var ResolveSite = ({ state, onSubmit }) => {
107768
107944
  const exit = useExit();
107769
107945
  const { model } = useProjectModel();
107770
107946
  const biLogger = useBiLogger();
107771
- return /* @__PURE__ */ import_react16.default.createElement(import_react16.default.Fragment, null, (0, import_variant11.match)(state, {
107772
- NotConfigured: (0, import_variant11.constant)(
107773
- /* @__PURE__ */ import_react16.default.createElement(Alert, { type: "insight" }, "You don't have a Development Site currently configured")
107947
+ return /* @__PURE__ */ import_react11.default.createElement(import_react11.default.Fragment, null, (0, import_variant8.match)(state, {
107948
+ NotConfigured: (0, import_variant8.constant)(
107949
+ /* @__PURE__ */ import_react11.default.createElement(Alert, { type: "insight" }, "You don't have a Development Site currently configured")
107774
107950
  ),
107775
- NotFound: ({ id }) => /* @__PURE__ */ import_react16.default.createElement(import_react16.default.Fragment, null, /* @__PURE__ */ import_react16.default.createElement(Alert, { type: "error" }, /* @__PURE__ */ import_react16.default.createElement(Text, null, "Your currently configured Development Site was not found (", id, ")")), /* @__PURE__ */ import_react16.default.createElement(Box_default, { flexDirection: "column" }, /* @__PURE__ */ import_react16.default.createElement(Text, null, "This may happen because the site was deleted or your access has been revoked."), /* @__PURE__ */ import_react16.default.createElement(Text, null, "Please select another Development Site to continue.")))
107776
- }), /* @__PURE__ */ import_react16.default.createElement(
107951
+ NotFound: ({ id }) => /* @__PURE__ */ import_react11.default.createElement(import_react11.default.Fragment, null, /* @__PURE__ */ import_react11.default.createElement(Alert, { type: "error" }, /* @__PURE__ */ import_react11.default.createElement(Text, null, "Your currently configured Development Site was not found (", id, ")")), /* @__PURE__ */ import_react11.default.createElement(Box_default, { flexDirection: "column" }, /* @__PURE__ */ import_react11.default.createElement(Text, null, "This may happen because the site was deleted or your access has been revoked."), /* @__PURE__ */ import_react11.default.createElement(Text, null, "Please select another Development Site to continue.")))
107952
+ }), /* @__PURE__ */ import_react11.default.createElement(
107777
107953
  SiteSelector,
107778
107954
  {
107779
107955
  appId: model.config.appId,
@@ -107786,54 +107962,49 @@ var ResolveSite = ({ state, onSubmit }) => {
107786
107962
 
107787
107963
  // ../cli-astro-commands/src/site/context.ts
107788
107964
  init_esm_shims();
107789
- var import_react17 = __toESM(require_react(), 1);
107790
- var SiteContext = (0, import_react17.createContext)(null);
107965
+ var import_react12 = __toESM(require_react(), 1);
107966
+ var SiteContext = (0, import_react12.createContext)(null);
107791
107967
 
107792
107968
  // ../cli-astro-commands/src/site/site-state.ts
107793
107969
  init_esm_shims();
107794
- var import_variant12 = __toESM(require_lib(), 1);
107795
- var SiteState = (0, import_variant12.variant)({
107970
+ var import_variant9 = __toESM(require_lib(), 1);
107971
+ var SiteState = (0, import_variant9.variant)({
107796
107972
  NotConfigured: {},
107797
- NotFound: (0, import_variant12.fields)(),
107798
- Resolved: (0, import_variant12.fields)()
107973
+ NotFound: (0, import_variant9.fields)(),
107974
+ Resolved: (0, import_variant9.fields)()
107799
107975
  });
107800
107976
 
107801
107977
  // ../cli-astro-commands/src/site/resolve-configured-site.ts
107802
107978
  init_esm_shims();
107803
107979
  async function resolveConfiguredSite({
107804
- projectFolder,
107805
107980
  siteListClient: { getSite },
107806
- siteId,
107807
- writeDebugLog
107981
+ siteId
107808
107982
  }) {
107809
- const resolvedSiteId = siteId ?? (await readAppConfig(projectFolder, writeDebugLog))?.siteId;
107810
- if (!resolvedSiteId) {
107983
+ if (!siteId) {
107811
107984
  return SiteState.NotConfigured();
107812
107985
  }
107813
- const site = await getSite(resolvedSiteId);
107986
+ const site = await getSite(siteId, true);
107814
107987
  if (!site) {
107815
- return SiteState.NotFound({ id: resolvedSiteId });
107988
+ return SiteState.NotFound({ id: siteId });
107816
107989
  }
107817
107990
  return SiteState.Resolved({ site });
107818
107991
  }
107819
107992
 
107820
107993
  // ../cli-astro-commands/src/site/SiteProvider.tsx
107821
- var SiteProvider = ({ children, siteId }) => {
107994
+ var SiteProvider = ({ children }) => {
107822
107995
  const exit = useExit();
107823
107996
  const {
107824
- model: { projectFolder }
107997
+ model: { projectFolder, config }
107825
107998
  } = useProjectModel();
107826
107999
  const writeDebugLog = useDebugLog();
107827
108000
  const siteListClient = useSiteListClient();
107828
108001
  const { status, merge } = useAsync(async () => {
107829
108002
  return resolveConfiguredSite({
107830
- projectFolder,
107831
108003
  siteListClient,
107832
- siteId,
107833
- writeDebugLog
108004
+ siteId: config.projectType === "Site" ? config.siteId : (await readAppConfig(projectFolder, writeDebugLog))?.siteId
107834
108005
  });
107835
108006
  }, []);
107836
- const setSite = (0, import_react18.useCallback)(
108007
+ const setSite = (0, import_react13.useCallback)(
107837
108008
  async (site) => {
107838
108009
  try {
107839
108010
  await saveAppConfig(projectFolder, { siteId: site.id });
@@ -107849,18 +108020,18 @@ var SiteProvider = ({ children, siteId }) => {
107849
108020
  },
107850
108021
  [merge, projectFolder]
107851
108022
  );
107852
- const handleResolveSite = (0, import_react18.useCallback)(
108023
+ const handleResolveSite = (0, import_react13.useCallback)(
107853
108024
  (site) => setSite(site).catch(exit),
107854
108025
  [exit, setSite]
107855
108026
  );
107856
- return (0, import_variant13.match)(status, {
108027
+ return (0, import_variant10.match)(status, {
107857
108028
  Error: () => null,
107858
- Loading: () => /* @__PURE__ */ import_react18.default.createElement(Spinner, { text: "Resolving development site..." }),
108029
+ Loading: () => /* @__PURE__ */ import_react13.default.createElement(Spinner, { text: "Resolving development site..." }),
107859
108030
  Success: ({ result: state }) => {
107860
- return (0, import_variant13.match)(state, {
107861
- NotConfigured: (variant7) => /* @__PURE__ */ import_react18.default.createElement(ResolveSite, { state: variant7, onSubmit: handleResolveSite }),
107862
- NotFound: (variant7) => /* @__PURE__ */ import_react18.default.createElement(ResolveSite, { state: variant7, onSubmit: handleResolveSite }),
107863
- Resolved: ({ site }) => /* @__PURE__ */ import_react18.default.createElement(
108031
+ return (0, import_variant10.match)(state, {
108032
+ NotConfigured: (variant5) => /* @__PURE__ */ import_react13.default.createElement(ResolveSite, { state: variant5, onSubmit: handleResolveSite }),
108033
+ NotFound: (variant5) => /* @__PURE__ */ import_react13.default.createElement(ResolveSite, { state: variant5, onSubmit: handleResolveSite }),
108034
+ Resolved: ({ site }) => /* @__PURE__ */ import_react13.default.createElement(
107864
108035
  SiteContext.Provider,
107865
108036
  {
107866
108037
  value: {
@@ -107875,445 +108046,312 @@ var SiteProvider = ({ children, siteId }) => {
107875
108046
  });
107876
108047
  };
107877
108048
 
108049
+ // ../cli-astro-commands/src/site/index.ts
108050
+ init_esm_shims();
108051
+
107878
108052
  // ../cli-astro-commands/src/site/useSite.ts
107879
108053
  init_esm_shims();
107880
- var import_react19 = __toESM(require_react(), 1);
108054
+ var import_react14 = __toESM(require_react(), 1);
107881
108055
  function useSite() {
107882
- const context = (0, import_react19.useContext)(SiteContext);
108056
+ const context = (0, import_react14.useContext)(SiteContext);
107883
108057
  if (context == null) {
107884
108058
  throw new Error("useSite() cannot be used without an <SiteProvider>");
107885
108059
  }
107886
108060
  return context;
107887
108061
  }
107888
108062
 
107889
- // ../cli-astro-commands/src/components/CloseScreen/index.tsx
107890
- init_esm_shims();
107891
-
107892
- // ../cli-astro-commands/src/components/CloseScreen/CloseScreen.tsx
107893
- init_esm_shims();
107894
- var import_react21 = __toESM(require_react(), 1);
107895
-
107896
- // ../cli-astro-commands/src/bi-app/index.ts
107897
- init_esm_shims();
107898
-
107899
- // ../cli-astro-commands/src/bi-app/useWixCliAppBi.ts
107900
- init_esm_shims();
107901
- var import_react20 = __toESM(require_react(), 1);
107902
-
107903
- // ../cli-astro-commands/src/bi-app/events.ts
108063
+ // ../cli-astro-commands/src/components/PreviewCommand/hooks/useUpdateManifest.ts
107904
108064
  init_esm_shims();
107905
- var wixCliAppBiEvents = (biLogger) => ({
107906
- cliAction: ({
107907
- questionKey,
107908
- question,
107909
- action,
107910
- key,
107911
- additionalInfo
108065
+ var import_react15 = __toESM(require_react(), 1);
108066
+ var componentHandlers = {
108067
+ [ComponentType.WEBHOOK]: ({ component, serverUrl, tunnelUrl }) => {
108068
+ component.compData.webhook.callbackUrl = normalizeUrl(
108069
+ component.compData.webhook.callbackUrl,
108070
+ tunnelUrl ?? serverUrl
108071
+ );
108072
+ },
108073
+ [ComponentType.BACK_OFFICE_PAGE]: ({ component, serverUrl }) => {
108074
+ component.compData.backOfficePage.iframeUrl = normalizeUrl(
108075
+ component.compData.backOfficePage.iframeUrl,
108076
+ serverUrl
108077
+ );
108078
+ },
108079
+ [ComponentType.BACK_OFFICE_EXTENSION_WIDGET]: ({ component, serverUrl }) => {
108080
+ component.compData.backOfficeExtensionWidget.iframeUrl = normalizeUrl(
108081
+ component.compData.backOfficeExtensionWidget.iframeUrl,
108082
+ serverUrl
108083
+ );
108084
+ },
108085
+ [ComponentType.BACK_OFFICE_MODAL]: ({ component, serverUrl }) => {
108086
+ component.compData.backOfficeModal.iframeUrl = normalizeUrl(
108087
+ component.compData.backOfficeModal.iframeUrl,
108088
+ serverUrl
108089
+ );
108090
+ },
108091
+ [ComponentType.BACK_OFFICE_EXTENSION_MENU_ITEM]: ({
108092
+ component,
108093
+ serverUrl
107912
108094
  }) => {
107913
- void biLogger.report(
107914
- wixCliAction({
107915
- questionKey,
107916
- question,
107917
- action,
107918
- key,
107919
- additionalInfo: JSON.stringify(additionalInfo)
107920
- })
108095
+ component.compData.backOfficeExtensionMenuItem.iframeUrl = normalizeUrl(
108096
+ component.compData.backOfficeExtensionMenuItem.iframeUrl,
108097
+ serverUrl
107921
108098
  );
107922
108099
  },
107923
- cliStepBack: ({
107924
- additionalInfo
108100
+ [ComponentType.ECOM_SHIPPING_RATES]: ({
108101
+ component,
108102
+ serverUrl,
108103
+ tunnelUrl
107925
108104
  }) => {
107926
- void biLogger.report(
107927
- wixCliAction({
107928
- action: "goToPreviousStep",
107929
- key: "Esc",
107930
- additionalInfo: JSON.stringify(additionalInfo)
107931
- })
108105
+ component.compData.ecomShippingRates.deploymentUri = normalizeUrl(
108106
+ component.compData.ecomShippingRates.deploymentUri,
108107
+ tunnelUrl ?? serverUrl
107932
108108
  );
107933
108109
  },
107934
- cliFlowStepAnswered: ({
107935
- question,
107936
- questionKey,
107937
- answer,
107938
- additionalInfo
108110
+ [ComponentType.ECOM_ADDITIONAL_FEES]: ({
108111
+ component,
108112
+ serverUrl,
108113
+ tunnelUrl
107939
108114
  }) => {
107940
- void biLogger.report(
107941
- wixCliAppFlowStepsAnswers({
107942
- questionKey,
107943
- question,
107944
- answer,
107945
- additionalInfo: JSON.stringify(additionalInfo)
107946
- })
108115
+ component.compData.ecomAdditionalFees.deploymentUri = normalizeUrl(
108116
+ component.compData.ecomAdditionalFees.deploymentUri,
108117
+ tunnelUrl ?? serverUrl
107947
108118
  );
107948
108119
  },
107949
- fileUpload({
107950
- provider,
107951
- fileCount,
107952
- totalSizeInKb,
107953
- cliVersion
107954
- }) {
107955
- const startTimestamp = Date.now();
107956
- void biLogger.report(
107957
- wixCliAppFlowFileUploadStarted({
107958
- timestampMs: startTimestamp,
107959
- hostingProvider: provider,
107960
- numFiles: fileCount,
107961
- fileSizeCompressed: 0,
107962
- fileSizeNotCompressed: totalSizeInKb,
107963
- cliVersion
107964
- })
108120
+ [ComponentType.ECOM_DISCOUNTS_TRIGGER]: ({
108121
+ component,
108122
+ serverUrl,
108123
+ tunnelUrl
108124
+ }) => {
108125
+ component.compData.ecomDiscountsTrigger.deploymentUri = normalizeUrl(
108126
+ component.compData.ecomDiscountsTrigger.deploymentUri,
108127
+ tunnelUrl ?? serverUrl
107965
108128
  );
107966
- return {
107967
- finished() {
107968
- void biLogger.report(
107969
- wixCliAppFlowUploadEnded({
107970
- duration: Date.now() - startTimestamp
107971
- })
107972
- );
107973
- }
107974
- };
107975
108129
  },
107976
- cliDeployment: ({
107977
- appId,
107978
- deploymentId,
107979
- files
108130
+ [ComponentType.ECOM_VALIDATIONS]: ({ component, serverUrl, tunnelUrl }) => {
108131
+ component.compData.ecomValidations.deploymentUri = normalizeUrl(
108132
+ component.compData.ecomValidations.deploymentUri,
108133
+ tunnelUrl ?? serverUrl
108134
+ );
108135
+ },
108136
+ [ComponentType.ECOM_PAYMENT_SETTINGS]: ({
108137
+ component,
108138
+ serverUrl,
108139
+ tunnelUrl
107980
108140
  }) => {
107981
- const startTimestamp = Date.now();
107982
- const fileDetails = files ? files.filter((f) => f.filePath).map((file) => ({
107983
- filePath: file.filePath,
107984
- fileSizeKb: file.content ? file.content.length / 1024 : 0
107985
- })) : [];
107986
- return {
107987
- finish: ({
107988
- isSuccess,
107989
- failureReason
107990
- }) => {
107991
- void biLogger.report(
107992
- wixCliAppsFlowDeploymentStatusSrc11Evid5232({
107993
- isSuccess,
107994
- failureReason,
107995
- filesDetails: JSON.stringify(fileDetails),
107996
- filesSize: Math.round(
107997
- fileDetails.reduce((acc, { fileSizeKb }) => acc + fileSizeKb, 0)
107998
- ),
107999
- uploadSource: "backend",
108000
- appId,
108001
- deploymentId,
108002
- filesUploadTime: Date.now() - startTimestamp
108003
- })
108004
- );
108005
- }
108006
- };
108141
+ component.compData.ecomPaymentSettings.deploymentUri = normalizeUrl(
108142
+ component.compData.ecomPaymentSettings.deploymentUri,
108143
+ tunnelUrl ?? serverUrl
108144
+ );
108145
+ },
108146
+ [ComponentType.GIFT_CARDS_PROVIDER]: ({
108147
+ component,
108148
+ serverUrl,
108149
+ tunnelUrl
108150
+ }) => {
108151
+ component.compData.giftCardsProvider.deploymentUri = normalizeUrl(
108152
+ component.compData.giftCardsProvider.deploymentUri,
108153
+ tunnelUrl ?? serverUrl
108154
+ );
108155
+ },
108156
+ [ComponentType.TOPOLOGY]: ({ component, serverUrl, tunnelUrl }) => {
108157
+ component.compData.topology.topology.backendApiUrl = tunnelUrl ?? serverUrl;
108007
108158
  }
108008
- });
108009
-
108010
- // ../cli-astro-commands/src/bi-app/useWixCliAppBi.ts
108011
- function useWixCliAppBi() {
108012
- const biLogger = useBiLogger();
108013
- return (0, import_react20.useMemo)(() => wixCliAppBiEvents(biLogger), [biLogger]);
108014
- }
108015
-
108016
- // ../cli-astro-commands/src/components/CloseScreen/CloseScreen.tsx
108017
- var CloseScreen = ({ onClose }) => {
108018
- const bi = useWixCliAppBi();
108019
- use_input_default((_, key) => {
108020
- if (key.escape) {
108021
- bi.cliAction({
108022
- question: "Press to close",
108023
- questionKey: "general.close_screen",
108024
- action: "close",
108025
- key: "esc"
108026
- });
108027
- onClose();
108028
- }
108029
- });
108030
- return /* @__PURE__ */ import_react21.default.createElement(Text, { skin: "secondary" }, "Press", /* @__PURE__ */ import_react21.default.createElement(Key, { value: "esc", skin: "secondary" }), "to close");
108031
108159
  };
108032
-
108033
- // ../cli-astro-commands/src/components/DevCommand/app-flow/SiteSelectorScreen.tsx
108034
- var SiteSelectorScreen = ({ onScreenChange }) => {
108035
- const { model } = useProjectModel();
108036
- const biLogger = useBiLogger();
108037
- const { site, setSite } = useSite();
108038
- const { reportError } = useErrorReporter();
108039
- const [error, setError] = (0, import_react22.useState)(null);
108040
- const handleError = (0, import_react22.useCallback)(
108041
- (error2) => {
108042
- reportError(error2);
108043
- setError(error2);
108160
+ function useUpdateManifest() {
108161
+ const updateManifest = (0, import_react15.useCallback)(
108162
+ (manifest, serverUrl, tunnelUrl) => {
108163
+ const clone = structuredClone(manifest);
108164
+ for (const component of clone.components) {
108165
+ const handler = getHandler(
108166
+ component,
108167
+ componentHandlers
108168
+ );
108169
+ handler?.({
108170
+ component,
108171
+ serverUrl,
108172
+ tunnelUrl
108173
+ });
108174
+ }
108175
+ return clone;
108044
108176
  },
108045
- [reportError, setError]
108177
+ []
108046
108178
  );
108047
- const handleSubmit = (0, import_react22.useCallback)(
108048
- async (site2) => {
108049
- try {
108050
- await setSite(site2);
108051
- onScreenChange(ScreenState.Home());
108052
- } catch (e) {
108053
- handleError(e);
108054
- }
108179
+ const updateManifestWithBackendWorker = (0, import_react15.useCallback)(
108180
+ (manifest, deploymentId, deploymentUrl, label, commitHash) => {
108181
+ const clone = structuredClone(manifest);
108182
+ clone.components.push({
108183
+ compId: BACKEND_WORKER_COMPONENT_ID,
108184
+ compType: ComponentType.BACKEND_WORKER,
108185
+ compData: {
108186
+ backendWorker: {
108187
+ deploymentId,
108188
+ deploymentUrl,
108189
+ label,
108190
+ commitHash
108191
+ }
108192
+ }
108193
+ });
108194
+ return clone;
108055
108195
  },
108056
- [setSite, onScreenChange, handleError]
108196
+ []
108057
108197
  );
108058
- return /* @__PURE__ */ import_react22.default.createElement(Box_default, { flexDirection: "column", gap: 1 }, /* @__PURE__ */ import_react22.default.createElement(Box_default, { gap: 1 }, /* @__PURE__ */ import_react22.default.createElement(PointerIcon, null), /* @__PURE__ */ import_react22.default.createElement(Text, null, "Current Development Site: ", site.displayName)), /* @__PURE__ */ import_react22.default.createElement(Box_default, { flexDirection: "column" }, /* @__PURE__ */ import_react22.default.createElement(
108059
- SiteSelector,
108060
- {
108061
- appId: model.config.appId,
108062
- biLogger,
108063
- onSubmit: handleSubmit,
108064
- onError: handleError
108065
- }
108066
- ), error ? /* @__PURE__ */ import_react22.default.createElement(
108067
- ErrorViewer,
108068
- {
108069
- error,
108070
- systemErrorOverride: /* @__PURE__ */ import_react22.default.createElement(Alert, { type: "error" }, "Failed to change Development Site!")
108071
- }
108072
- ) : null), /* @__PURE__ */ import_react22.default.createElement(CloseScreen, { onClose: () => onScreenChange(ScreenState.Home()) }));
108073
- };
108198
+ return {
108199
+ updateManifest,
108200
+ updateManifestWithBackendWorker
108201
+ };
108202
+ }
108203
+ function getHandler(component, handlers) {
108204
+ return handlers[component.compType];
108205
+ }
108206
+ function normalizeUrl(inputUrl, baseUrl) {
108207
+ if (!inputUrl) {
108208
+ return baseUrl;
108209
+ }
108210
+ if (URL.canParse(inputUrl)) {
108211
+ return inputUrl;
108212
+ }
108213
+ const base = new URL(baseUrl);
108214
+ const normalizedUrl = new URL(inputUrl, base);
108215
+ if (base.search) {
108216
+ normalizedUrl.search = base.search;
108217
+ }
108218
+ return normalizedUrl.href;
108219
+ }
108074
108220
 
108075
- // ../cli-astro-commands/src/components/DevCommand/app-flow/HomeScreen.tsx
108221
+ // ../cli-astro-commands/src/components/PlatformLink/PlatformLink.tsx
108076
108222
  init_esm_shims();
108077
- var import_react23 = __toESM(require_react(), 1);
108078
- var HomeScreen = ({
108079
- onScreenChange,
108080
- devArmTag
108081
- }) => {
108082
- const { site } = useSite();
108083
- const bi = useWixCliAppBi();
108084
- use_input_default(async (input) => {
108085
- if (input === "c") {
108086
- bi.cliAction({
108087
- question: "Switch Dev Site",
108088
- questionKey: "dev_command.dev_site.change",
108089
- action: "change_site",
108090
- key: input
108091
- });
108092
- onScreenChange(ScreenState.SiteSelector());
108093
- }
108094
- });
108095
- return /* @__PURE__ */ import_react23.default.createElement(import_react23.default.Fragment, null, /* @__PURE__ */ import_react23.default.createElement(Box_default, { gap: 1 }, /* @__PURE__ */ import_react23.default.createElement(Text, null, "Current Dev Site:"), /* @__PURE__ */ import_react23.default.createElement(Text, { bold: true, skin: "info" }, site.displayName), /* @__PURE__ */ import_react23.default.createElement(Text, { skin: "secondary" }, "(Press ", /* @__PURE__ */ import_react23.default.createElement(Key, { value: "C", skin: "secondary" }), " to switch)")), /* @__PURE__ */ import_react23.default.createElement(Box_default, { paddingTop: 1, paddingBottom: 1, flexDirection: "column" }, /* @__PURE__ */ import_react23.default.createElement(Text, null, "Open the preview on:"), /* @__PURE__ */ import_react23.default.createElement(Box_default, { paddingLeft: 2, flexDirection: "column" }, devArmTag ? /* @__PURE__ */ import_react23.default.createElement(
108096
- PlatformLink,
108097
- {
108098
- url: `https://manage.wix.com/dashboard/${site.id}?apps-override=${devArmTag}`,
108099
- label: "Dashboard"
108100
- }
108101
- ) : /* @__PURE__ */ import_react23.default.createElement(Spinner, { text: "Preparing your dashboard..." }))));
108223
+ var import_react16 = __toESM(require_react(), 1);
108224
+ var PlatformLink = ({ url, label }) => {
108225
+ return /* @__PURE__ */ import_react16.default.createElement(Box_default, { marginRight: 1 }, /* @__PURE__ */ import_react16.default.createElement(PointerSmallIcon, null), /* @__PURE__ */ import_react16.default.createElement(Box_default, { marginLeft: 1 }, /* @__PURE__ */ import_react16.default.createElement(Link, { url }, label)));
108102
108226
  };
108103
108227
 
108104
- // ../cli-astro-commands/src/components/DevCommand/hooks/useDevCenterUpdater.ts
108228
+ // ../cli-astro-commands/src/hooks/useUpdateDeploymentTopology.ts
108105
108229
  init_esm_shims();
108106
- var import_react24 = __toESM(require_react(), 1);
108107
- var import_variant14 = __toESM(require_lib(), 1);
108108
- import { isDeepStrictEqual as isDeepStrictEqual2 } from "node:util";
108109
- var DevCenterUpdateResult2 = (0, import_variant14.variant)({
108110
- Changed: (0, import_variant14.fields)(),
108111
- Unchanged: {}
108112
- });
108113
- var useDevCenterUpdater = ({
108114
- serverLocalUrl,
108115
- serverExposedUrl,
108116
- devMetadata
108117
- }) => {
108118
- const [devArmTag, setDevArmTag] = (0, import_react24.useState)();
108119
- const [manifest, setManifest] = (0, import_react24.useState)(null);
108120
- const writeToDebugLog = useDebugLog();
108230
+ function useUpdateDeploymentTopology(siteId) {
108121
108231
  const {
108122
- model: {
108123
- config: { appId },
108124
- projectFolder
108125
- }
108232
+ model: { projectFolder }
108126
108233
  } = useProjectModel();
108127
- const logger = (0, import_react24.useMemo)(() => createAstroLogger(), []);
108128
- const { updateManifest } = useUpdateManifest();
108129
- const arm = useARMClient();
108130
- const openTunnel = useTunnel();
108131
- const tunnelUrl = (0, import_react24.useRef)();
108132
- const [tunnelRequired, setTunnelRequired] = (0, import_react24.useState)(false);
108133
- const fetchAppManifest = useFetchAppManifest();
108134
- const updateDevCenter = (0, import_react24.useCallback)(async () => {
108135
- const baseUrl = serverExposedUrl ?? serverLocalUrl;
108136
- const { manifest: latestManifest, isTunnelRequired: isTunnelRequired2 } = await fetchAppManifest(
108137
- serverLocalUrl,
108138
- devMetadata,
108139
- baseUrl,
108140
- tunnelUrl.current ?? baseUrl
108141
- );
108142
- if (isDeepStrictEqual2(manifest, latestManifest)) {
108143
- return DevCenterUpdateResult2.Unchanged();
108144
- }
108145
- if (!serverExposedUrl && !tunnelUrl.current && isTunnelRequired2) {
108146
- const config = await readUserConfig();
108147
- if (!config.tunneling) {
108148
- setTunnelRequired(true);
108149
- return DevCenterUpdateResult2.Unchanged();
108150
- }
108151
- const serverLocalPort = parseInt(new URL(serverLocalUrl).port, 10);
108152
- const tunnel = await openTunnel(serverLocalPort);
108153
- tunnelUrl.current = tunnel.url;
108154
- return DevCenterUpdateResult2.Unchanged();
108155
- }
108156
- const appConfig = await readAppConfig(projectFolder);
108157
- let updatedDevArmTag = appConfig?.devArmTag;
108158
- if (!updatedDevArmTag) {
108159
- updatedDevArmTag = await arm.createLooseAppRelease(
108160
- updateManifest(latestManifest, baseUrl, tunnelUrl.current),
108161
- appId
108162
- );
108163
- } else {
108164
- const updateState = await arm.updateLooseAppRelease(
108165
- updateManifest(latestManifest, baseUrl, tunnelUrl.current),
108166
- updatedDevArmTag
108167
- );
108168
- if (!(0, import_variant14.isType)(updateState, "TagUpdated")) {
108169
- updatedDevArmTag = await arm.createLooseAppRelease(
108170
- updateManifest(latestManifest, baseUrl, tunnelUrl.current),
108171
- appId
108172
- );
108173
- }
108174
- }
108175
- if (updatedDevArmTag !== appConfig?.devArmTag) {
108176
- await saveAppConfig(projectFolder, { devArmTag: updatedDevArmTag });
108177
- }
108178
- setManifest(latestManifest);
108179
- setDevArmTag(updatedDevArmTag);
108180
- const armTagChanged = !!appConfig?.devArmTag && updatedDevArmTag !== appConfig.devArmTag;
108181
- return DevCenterUpdateResult2.Changed({ armTagChanged });
108182
- }, [
108183
- fetchAppManifest,
108184
- updateManifest,
108185
- serverLocalUrl,
108186
- serverExposedUrl,
108187
- arm,
108188
- manifest,
108189
- projectFolder,
108190
- appId,
108191
- openTunnel,
108192
- devMetadata
108193
- ]);
108194
- const [timer, setTimer] = (0, import_react24.useState)(Date.now());
108195
- (0, import_react24.useEffect)(() => {
108196
- let disposed = false;
108197
- void updateDevCenter().then((result) => {
108198
- if ((0, import_variant14.isType)(result, "Changed")) {
108199
- logger.log(
108200
- "App Manifest updated. Refresh existing browser tabs to view the latest changes."
108201
- );
108202
- }
108203
- }).catch((error) => {
108204
- logger.log("Failed to update App Manifest");
108205
- logger.log(`${error}`);
108206
- writeToDebugLog(error);
108207
- }).then(() => {
108208
- if (!disposed) {
108209
- setTimeout(() => setTimer(Date.now()), 1e3);
108234
+ return useAsyncCallback(async (_, props) => {
108235
+ const { environment, siteUrl, armTag } = props;
108236
+ const topology = await readDeploymentTopology(projectFolder);
108237
+ topology[environment] = {
108238
+ id: armTag,
108239
+ site: siteUrl ? {
108240
+ main: siteUrl
108241
+ } : void 0,
108242
+ dashboard: {
108243
+ main: `https://manage.wix.com/dashboard/${siteId}?apps-override=${armTag}`
108210
108244
  }
108211
- });
108212
- return () => {
108213
- disposed = true;
108214
108245
  };
108215
- }, [timer]);
108216
- return { tunnelRequired, devArmTag };
108217
- };
108218
-
108219
- // ../cli-astro-commands/src/components/DevCommand/app-flow/AppDev.tsx
108220
- var AppDev = ({
108221
- serverLocalUrl,
108222
- serverExposedUrl,
108223
- devMetadata
108224
- }) => {
108225
- const [screen, setScreen] = (0, import_react25.useState)(ScreenState.Home());
108226
- const { tunnelRequired, devArmTag } = useDevCenterUpdater({
108227
- serverLocalUrl,
108228
- serverExposedUrl,
108229
- devMetadata
108246
+ const path = getDeploymentTopologyPath(projectFolder);
108247
+ await writeJson(path, topology, { spaces: 2 });
108230
108248
  });
108231
- return /* @__PURE__ */ import_react25.default.createElement(TunnelingConsent, { required: tunnelRequired }, (0, import_variant15.match)(screen, {
108232
- Home: () => /* @__PURE__ */ import_react25.default.createElement(HomeScreen, { onScreenChange: setScreen, devArmTag }),
108233
- SiteSelector: () => /* @__PURE__ */ import_react25.default.createElement(SiteSelectorScreen, { onScreenChange: setScreen })
108234
- }));
108235
- };
108236
-
108237
- // ../cli-astro-commands/src/components/DevCommand/AppDevFlow.tsx
108238
- var AppDevFlow = ({
108239
- devMetadataStatus,
108240
- serverExposedUrl
108241
- }) => {
108242
- return (0, import_variant16.match)(devMetadataStatus, {
108243
- NotRequested: () => /* @__PURE__ */ import_react26.default.createElement(Spinner, { text: "Starting dev environment..." }),
108244
- Error: () => null,
108245
- Loading: () => /* @__PURE__ */ import_react26.default.createElement(Spinner, { text: "Checking dev environment settings..." }),
108246
- Success: ({ result: { devMetadata, serverLocalUrl } }) => {
108247
- return /* @__PURE__ */ import_react26.default.createElement(DevScreenBorder, null, /* @__PURE__ */ import_react26.default.createElement(SiteProvider, null, /* @__PURE__ */ import_react26.default.createElement(
108248
- AppDev,
108249
- {
108250
- serverLocalUrl,
108251
- serverExposedUrl,
108252
- devMetadata
108253
- }
108254
- )));
108249
+ }
108250
+ async function readDeploymentTopology(projectFolder) {
108251
+ const path = getDeploymentTopologyPath(projectFolder);
108252
+ if (await pathExists(path)) {
108253
+ try {
108254
+ const deployment = await readJson(path);
108255
+ return deploymentTopologySchema.parse(deployment);
108256
+ } catch {
108255
108257
  }
108256
- });
108257
- };
108258
+ }
108259
+ return {};
108260
+ }
108258
108261
 
108259
- // ../cli-astro-commands/src/components/DevCommand/DevCommand.tsx
108260
- var DevCommand = ({
108261
- port,
108262
- allowedHosts,
108263
- serverExposedUrl
108264
- }) => {
108265
- const {
108266
- model: { config, projectFolder }
108267
- } = useProjectModel();
108268
- const logger = (0, import_react27.useMemo)(() => createAstroLogger(false), []);
108269
- const astroProcess = (0, import_react27.useRef)();
108270
- const fetchDevMetadataAction = useFetchDevMetadata();
108271
- useAsync(async () => {
108272
- const repoType = await getRepoType(projectFolder);
108273
- const packageManager = await createPackageManager(repoType);
108274
- const astro = runAstroDev({
108275
- packageManager,
108276
- projectFolder,
108277
- port,
108278
- allowedHosts
108279
- });
108280
- astroProcess.current = astro;
108281
- astro.stdout?.once(EVENT_SERVER_ADDRESS, (address) => {
108282
- void fetchDevMetadataAction.execute(address);
108283
- });
108284
- astro.stdout?.on(EVENT_LINE, (line) => logger.log(line));
108285
- astro.stderr?.on(EVENT_LINE, (line) => logger.log(line));
108286
- }, []);
108287
- (0, import_react27.useEffect)(() => {
108288
- return () => {
108289
- if (astroProcess.current?.pid) {
108290
- try {
108291
- astroProcess.current.kill("SIGTERM");
108292
- } catch {
108293
- }
108294
- }
108295
- };
108296
- }, []);
108297
- if (config.projectType === "Site") {
108298
- return /* @__PURE__ */ import_react27.default.createElement(
108299
- SiteDevFlow,
108300
- {
108301
- siteId: config.siteId,
108302
- devMetadataStatus: fetchDevMetadataAction.status,
108303
- serverExposedUrl
108304
- }
108305
- );
108262
+ // ../cli-astro-commands/src/components/PreviewCommand/app-flow/useResolvePlatformUrl.ts
108263
+ init_esm_shims();
108264
+ var import_react17 = __toESM(require_react(), 1);
108265
+ var import_variant11 = __toESM(require_lib(), 1);
108266
+ var redirectWithCSMv2FTs = (url, platformType) => {
108267
+ const elgarBaseURL = (0, import_variant11.isType)(platformType, PlatformType.Site) ? `${url.origin}/_api` : "https://apps.wix.com";
108268
+ const elgarRedirectUrl = new URL(`${elgarBaseURL}/elgar-server/redirect`);
108269
+ const petriOvr = [
108270
+ // TODO: Remove once Dev Versions effort is done https://wix.atlassian.net/browse/FEDINF-13336
108271
+ "specs.UseAppsRuntimeCache",
108272
+ "specs.ApplyQueryParamsOverrides",
108273
+ "specs.ExcludeSiteFromSsrCache",
108274
+ // TODO: Remove once Blocks on CLI effort is done
108275
+ "specs.thunderbolt.passWidgetBundleUrls",
108276
+ "specs.thunderbolt.passBlocksWidgetBundleUrls",
108277
+ "specs.blocks-client.useBundledWidgetCode",
108278
+ "specs.blocks-widget-services.usePanelExtension"
108279
+ ];
108280
+ for (const spec of petriOvr) {
108281
+ elgarRedirectUrl.searchParams.append("experiments", `${spec}#true`);
108306
108282
  }
108307
- return /* @__PURE__ */ import_react27.default.createElement(
108308
- AppDevFlow,
108309
- {
108310
- devMetadataStatus: fetchDevMetadataAction.status,
108311
- serverExposedUrl
108312
- }
108283
+ elgarRedirectUrl.searchParams.append("redirectToUrl", url.toString());
108284
+ elgarRedirectUrl.searchParams.append("staticsVersions", "{}");
108285
+ return elgarRedirectUrl;
108286
+ };
108287
+ function useResolvePlatformUrl() {
108288
+ const { model } = useProjectModel();
108289
+ const { site } = useSite();
108290
+ return (0, import_react17.useCallback)(
108291
+ ({
108292
+ platformType,
108293
+ armTag,
108294
+ openAddPanel
108295
+ }) => {
108296
+ return resolvePlatformUrl(platformType, {
108297
+ openAddPanel,
108298
+ site,
108299
+ appId: model.config.appId,
108300
+ tag: armTag
108301
+ });
108302
+ },
108303
+ [site, model.config.appId]
108313
108304
  );
108305
+ }
108306
+ function resolvePlatformUrl(platformType, options) {
108307
+ const { site, tag, appId, openAddPanel } = options;
108308
+ const url = (0, import_variant11.match)(platformType, {
108309
+ Dashboard: () => new URL(`dashboard/${site.id}`, "https://manage.wix.com/"),
108310
+ Editor: () => {
108311
+ const editorUrl = new URL(`https://wix.com/editor/${site.id}`);
108312
+ if (openAddPanel) {
108313
+ editorUrl.searchParams.append("deeplink", `addpanel!${appId}`);
108314
+ }
108315
+ return editorUrl;
108316
+ },
108317
+ Site: () => {
108318
+ return site.viewUrl ? new URL(site.viewUrl) : void 0;
108319
+ },
108320
+ Blocks: () => new URL(`https://wix.com/editor/${site.id}`)
108321
+ });
108322
+ if (url) {
108323
+ url.searchParams.append("apps-override", tag);
108324
+ return (0, import_variant11.isOfVariant)(
108325
+ platformType,
108326
+ (0, import_variant11.variantList)([PlatformType.Editor, PlatformType.Site])
108327
+ ) ? redirectWithCSMv2FTs(url, platformType).toString() : url.toString();
108328
+ }
108329
+ }
108330
+
108331
+ // ../cli-astro-commands/src/components/PreviewCommand/app-flow/LivesiteLinkForApp.tsx
108332
+ init_esm_shims();
108333
+ var import_react18 = __toESM(require_react(), 1);
108334
+ var LivesiteLinkForApp = ({ armTag }) => {
108335
+ const resolvePlatformUrl2 = useResolvePlatformUrl();
108336
+ const siteUrl = resolvePlatformUrl2({
108337
+ platformType: PlatformType.Site(),
108338
+ armTag
108339
+ });
108340
+ return siteUrl ? /* @__PURE__ */ import_react18.default.createElement(PlatformLink, { url: siteUrl, label: "Site" }) : /* @__PURE__ */ import_react18.default.createElement(Box_default, { marginRight: 1 }, /* @__PURE__ */ import_react18.default.createElement(PointerSmallIcon, null), /* @__PURE__ */ import_react18.default.createElement(Box_default, { marginLeft: 1 }, /* @__PURE__ */ import_react18.default.createElement(Text, { skin: "secondary", underline: true }, "Site (publish your site to enable preview)")));
108314
108341
  };
108342
+
108315
108343
  export {
108316
- DevCommand
108344
+ useARMClient,
108345
+ useUpdateManifest,
108346
+ PlatformLink,
108347
+ useUpdateDeploymentTopology,
108348
+ useSite,
108349
+ readAppConfig,
108350
+ saveAppConfig,
108351
+ SiteSelector,
108352
+ SiteProvider,
108353
+ useResolvePlatformUrl,
108354
+ LivesiteLinkForApp
108317
108355
  };
108318
108356
  /*! Bundled license information:
108319
108357
 
@@ -108369,4 +108407,4 @@ export {
108369
108407
  *)
108370
108408
  *)
108371
108409
  */
108372
- //# sourceMappingURL=DevCommand-XWXE2GQD.js.map
108410
+ //# sourceMappingURL=chunk-5Z6Q4IJX.js.map