@wix/cli 1.1.132 → 1.1.133

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