@farm.js/core 0.1.60 → 0.1.62

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 (265) hide show
  1. package/dist/{agent-mcp.d-C-2S9bnP.d.mts → agent-mcp.d-BKZ3UNbt.d.mts} +1 -1
  2. package/dist/{agent-mcp.d-SIoCUP1I.d.ts → agent-mcp.d-C1zr_nGS.d.ts} +1 -1
  3. package/dist/agent-runtime.cjs +3 -3
  4. package/dist/agent-runtime.d.mts +2 -2
  5. package/dist/agent-runtime.d.ts +2 -2
  6. package/dist/agent-runtime.mjs +2 -2
  7. package/dist/analyzer-2AHWJJR7.cjs +15 -0
  8. package/dist/analyzer-YESYU3GK.mjs +15 -0
  9. package/dist/api/route-manager.cjs +4 -4
  10. package/dist/api/route-manager.d.mts +4 -4
  11. package/dist/api/route-manager.d.ts +4 -4
  12. package/dist/api/route-manager.mjs +3 -3
  13. package/dist/api/runtime.cjs +3 -3
  14. package/dist/api/runtime.d.mts +3 -3
  15. package/dist/api/runtime.d.ts +3 -3
  16. package/dist/api/runtime.mjs +2 -2
  17. package/dist/api.cjs +5 -5
  18. package/dist/api.d.mts +4 -4
  19. package/dist/api.d.ts +4 -4
  20. package/dist/api.mjs +4 -4
  21. package/dist/{app-manifest.d-DrSAHskY.d.mts → app-manifest.d-BpvhfKRH.d.mts} +1 -1
  22. package/dist/{app-manifest.d-Tb3CJpL4.d.ts → app-manifest.d-ntch_bvA.d.ts} +1 -1
  23. package/dist/app-markdown.d.mts +3 -3
  24. package/dist/app-markdown.d.ts +3 -3
  25. package/dist/{app.d-CmWlYpZJ.d.ts → app.d-AE8_v3Db.d.ts} +4 -10
  26. package/dist/{app.d-D6QQM_kk.d.mts → app.d-CysWA_8v.d.mts} +4 -10
  27. package/dist/{chunk-FORSVMEJ.mjs → chunk-2CNKQC3G.mjs} +1 -1
  28. package/dist/{chunk-ZFUKPWFC.mjs → chunk-2JYBLE63.mjs} +416 -208
  29. package/dist/{chunk-QRX4JRBO.cjs → chunk-3CCAICF7.cjs} +5 -5
  30. package/dist/{chunk-ANHZ6SUL.mjs → chunk-3TXKFRSO.mjs} +1 -1
  31. package/dist/{chunk-BHJAYPYU.mjs → chunk-3UZVPO72.mjs} +1 -1
  32. package/dist/{chunk-6UUH4N4J.mjs → chunk-43V3ANPQ.mjs} +1 -1
  33. package/dist/chunk-4EBC7EMW.cjs +8 -0
  34. package/dist/{chunk-VZY7MAVS.cjs → chunk-4IHMHFQB.cjs} +27 -1
  35. package/dist/{chunk-FK25QSVC.cjs → chunk-4P5634G6.cjs} +2 -2
  36. package/dist/{chunk-4JTQPOKO.cjs → chunk-53ZCZ46B.cjs} +2 -2
  37. package/dist/{chunk-NQJDO7K7.cjs → chunk-545WJ5UG.cjs} +321 -37
  38. package/dist/{chunk-VU3MYZPO.mjs → chunk-5FE5YT2N.mjs} +26 -0
  39. package/dist/{chunk-A5BJKSZE.cjs → chunk-5IQ2ERQA.cjs} +2 -2
  40. package/dist/{chunk-SJRCWF4Z.mjs → chunk-5Y22WNTO.mjs} +2 -2
  41. package/dist/{chunk-U4BJKNIR.cjs → chunk-752XUZIM.cjs} +11 -6
  42. package/dist/{chunk-JBK7UJOI.cjs → chunk-AJB3DHN6.cjs} +2 -2
  43. package/dist/{chunk-YB44NKC2.cjs → chunk-AXVRUDMB.cjs} +2 -2
  44. package/dist/{chunk-LJVNMGE3.mjs → chunk-BM2LH2JM.mjs} +8 -3
  45. package/dist/{chunk-YI6FKTTN.cjs → chunk-BT4SEFLC.cjs} +261 -38
  46. package/dist/{chunk-LIFUPCXW.cjs → chunk-CFG4QERR.cjs} +13 -2
  47. package/dist/{chunk-3OWVWZ6R.cjs → chunk-CLFEQGET.cjs} +6 -6
  48. package/dist/{chunk-OZK2DS44.mjs → chunk-CROAFCMW.mjs} +1 -1
  49. package/dist/{chunk-2KTYMMWT.mjs → chunk-DPE53XWL.mjs} +1 -1
  50. package/dist/{chunk-3PX4AIXO.mjs → chunk-DQF3QLOH.mjs} +258 -35
  51. package/dist/{chunk-FSQMN2MQ.mjs → chunk-E46NXBNJ.mjs} +1 -1
  52. package/dist/{chunk-EGVC4LIG.mjs → chunk-E4RDMG3K.mjs} +1 -1
  53. package/dist/{chunk-X2CZTWQA.mjs → chunk-ECKQFEX2.mjs} +1 -1
  54. package/dist/{chunk-MTWXOEI4.cjs → chunk-EXXFSZOC.cjs} +246 -193
  55. package/dist/{chunk-UYSTTPYJ.cjs → chunk-GGNJAGGE.cjs} +643 -435
  56. package/dist/{chunk-XTG73QZA.cjs → chunk-GVOMPU3Y.cjs} +12 -8
  57. package/dist/{chunk-ZP32GNJQ.cjs → chunk-I32V5CZL.cjs} +14 -13
  58. package/dist/{chunk-37PYUEK5.mjs → chunk-IOF4KXMP.mjs} +7 -3
  59. package/dist/{chunk-ILMTRGBG.mjs → chunk-IQIKPKFP.mjs} +157 -45
  60. package/dist/{chunk-5JNUYGNF.cjs → chunk-IWRLV46X.cjs} +2 -2
  61. package/dist/{chunk-KPOMS5RO.cjs → chunk-J3GFOQOL.cjs} +3 -3
  62. package/dist/{chunk-NHD7BAKD.mjs → chunk-JCEFKP5M.mjs} +41 -25
  63. package/dist/{analyzer-LCSI3NSH.cjs → chunk-JEJQGZI7.cjs} +16 -13
  64. package/dist/{chunk-LB3DPQP6.cjs → chunk-JLDNXURZ.cjs} +23 -23
  65. package/dist/{chunk-VGG74PSU.cjs → chunk-L2JG337G.cjs} +2 -2
  66. package/dist/chunk-L4RTTTVE.mjs +8 -0
  67. package/dist/chunk-LEJDW34D.cjs +115 -0
  68. package/dist/{analyzer-22BEYV7S.mjs → chunk-LVWGURLD.mjs} +6 -3
  69. package/dist/{chunk-Z5A6CNV2.mjs → chunk-MK5E44WP.mjs} +1 -1
  70. package/dist/{chunk-T4EW7AAD.mjs → chunk-NKRZLQUK.mjs} +2 -2
  71. package/dist/{chunk-HPWB57PZ.mjs → chunk-NT3QDN2E.mjs} +1 -1
  72. package/dist/{chunk-T7I62A4C.mjs → chunk-OUWRNHTV.mjs} +81 -28
  73. package/dist/{chunk-GFT5AHAT.mjs → chunk-QDWMCFTH.mjs} +12 -1
  74. package/dist/{chunk-AER5I65K.mjs → chunk-QTD6EMN2.mjs} +1 -1
  75. package/dist/{chunk-UDJY2ZGY.cjs → chunk-RMUD75WT.cjs} +413 -301
  76. package/dist/chunk-RZNCMRD3.mjs +141 -0
  77. package/dist/{chunk-D7LTCK3U.mjs → chunk-SA7MLSP4.mjs} +11 -6
  78. package/dist/{chunk-2FRLSDBT.cjs → chunk-SM25ZC4S.cjs} +1 -1
  79. package/dist/{chunk-3YMLUNL2.cjs → chunk-SVXOCTQ2.cjs} +1 -1
  80. package/dist/{chunk-W2RZ73IU.cjs → chunk-SYXPWJ7N.cjs} +8 -8
  81. package/dist/{chunk-F6Y7ZAPQ.mjs → chunk-T46NNU4D.mjs} +6 -3
  82. package/dist/{chunk-IFHPDLIS.mjs → chunk-TGULJSHD.mjs} +5 -4
  83. package/dist/{chunk-JPIUGDK4.mjs → chunk-TZVUF5JJ.mjs} +1 -1
  84. package/dist/chunk-UWI3SJAK.cjs +141 -0
  85. package/dist/{chunk-JI5D7MXY.mjs → chunk-UYRI6U3P.mjs} +1 -1
  86. package/dist/{chunk-D2X5MUF5.cjs → chunk-V727H3RI.cjs} +47 -31
  87. package/dist/{chunk-ZMHAFH4R.mjs → chunk-VM7X5CKC.mjs} +2 -2
  88. package/dist/{chunk-VPTWKOCY.mjs → chunk-VWW4Q3BJ.mjs} +287 -6
  89. package/dist/{chunk-4P23B7DU.cjs → chunk-WKJQ2FJA.cjs} +3 -3
  90. package/dist/{chunk-HASX6DC7.cjs → chunk-WKPBIT5Q.cjs} +8 -8
  91. package/dist/{chunk-RAWWCDCT.cjs → chunk-WYAXRIYP.cjs} +3 -3
  92. package/dist/{chunk-3TL3AH25.cjs → chunk-X4K7TYN6.cjs} +12 -7
  93. package/dist/chunk-XCXHQBMM.mjs +115 -0
  94. package/dist/{chunk-DPJ66FSI.cjs → chunk-XX32BOMM.cjs} +7 -7
  95. package/dist/{chunk-2IAPKPEB.cjs → chunk-YN6BHOYY.cjs} +6 -6
  96. package/dist/{chunk-CBKRS3M4.cjs → chunk-Z7P2BTZ3.cjs} +7 -6
  97. package/dist/{chunk-SX7EECTS.mjs → chunk-ZBUAOGMY.mjs} +1 -1
  98. package/dist/{chunk-RPUJHJHE.mjs → chunk-ZFWYCVKS.mjs} +4 -3
  99. package/dist/{chunk-IFXSBJPN.cjs → chunk-ZVIEFTUA.cjs} +20 -17
  100. package/dist/{chunk-EXUONJYV.mjs → chunk-ZZI56IUY.mjs} +3 -3
  101. package/dist/{programmatic-routes-client.d-CLG2N1yH.d.ts → client-component.d-Bgt3x5Fu.d.ts} +18 -3
  102. package/dist/{programmatic-routes-client.d-CPbNqtIi.d.mts → client-component.d-BoqC2MLC.d.mts} +18 -3
  103. package/dist/{client-plugins.d-vXrbcfJ1.d.ts → client-plugins.d-BcqIy4au.d.ts} +1 -1
  104. package/dist/{client-plugins.d-CgQQ-EAv.d.mts → client-plugins.d-CWyYBxXf.d.mts} +1 -1
  105. package/dist/client-plugins.d.mts +2 -2
  106. package/dist/client-plugins.d.ts +2 -2
  107. package/dist/client.d.mts +7 -7
  108. package/dist/client.d.ts +7 -7
  109. package/dist/{config.d-DqZkLwef.d.ts → config.d-qt-mE8O5.d.mts} +6 -2
  110. package/dist/{config.d-DqZkLwef.d.mts → config.d-qt-mE8O5.d.ts} +6 -2
  111. package/dist/config.d.mts +2 -2
  112. package/dist/config.d.ts +2 -2
  113. package/dist/cron.cjs +12 -2
  114. package/dist/cron.d.mts +101 -3
  115. package/dist/cron.d.ts +101 -3
  116. package/dist/cron.mjs +11 -1
  117. package/dist/desktop.d.mts +3 -3
  118. package/dist/desktop.d.ts +3 -3
  119. package/dist/{devtools-KQZ6SRCJ.mjs → devtools-NUVXYG7I.mjs} +6 -6
  120. package/dist/{devtools-UF6JYHUN.cjs → devtools-SVRSGPNC.cjs} +8 -8
  121. package/dist/docs.cjs +9 -9
  122. package/dist/docs.d.mts +3 -3
  123. package/dist/docs.d.ts +3 -3
  124. package/dist/docs.mjs +8 -8
  125. package/dist/image/server.cjs +3 -3
  126. package/dist/image/server.mjs +2 -2
  127. package/dist/image/sharp.cjs +10 -10
  128. package/dist/image/sharp.mjs +2 -2
  129. package/dist/index.cjs +42 -27
  130. package/dist/{index.d-Dmfb7Kb_.d.mts → index.d-BDaiu2i5.d.mts} +1 -1
  131. package/dist/{index.d-DlCELfhf.d.ts → index.d-nAncqTXz.d.ts} +1 -1
  132. package/dist/index.d.mts +18 -18
  133. package/dist/index.d.ts +18 -18
  134. package/dist/index.mjs +42 -27
  135. package/dist/integrations.cjs +3 -3
  136. package/dist/integrations.d.mts +2 -2
  137. package/dist/integrations.d.ts +2 -2
  138. package/dist/integrations.mjs +2 -2
  139. package/dist/internal/app-markdown-runtime.d.mts +3 -3
  140. package/dist/internal/app-markdown-runtime.d.ts +3 -3
  141. package/dist/internal/build-runtime.cjs +27 -22
  142. package/dist/internal/build-runtime.d.mts +4 -4
  143. package/dist/internal/build-runtime.d.ts +4 -4
  144. package/dist/internal/build-runtime.mjs +26 -21
  145. package/dist/internal/cli-runtime.cjs +12 -11
  146. package/dist/internal/cli-runtime.mjs +11 -10
  147. package/dist/internal/client-error-overlay.cjs +4 -4
  148. package/dist/internal/client-error-overlay.mjs +1 -1
  149. package/dist/internal/client-runtime.d.mts +5 -5
  150. package/dist/internal/client-runtime.d.ts +5 -5
  151. package/dist/internal/compression-runtime.d.mts +2 -2
  152. package/dist/internal/compression-runtime.d.ts +2 -2
  153. package/dist/internal/config-runtime.cjs +8 -8
  154. package/dist/internal/config-runtime.d.mts +5 -5
  155. package/dist/internal/config-runtime.d.ts +5 -5
  156. package/dist/internal/config-runtime.mjs +7 -7
  157. package/dist/internal/form-actions.cjs +4 -4
  158. package/dist/internal/form-actions.mjs +3 -3
  159. package/dist/internal/infra-analytics-runtime.cjs +6 -6
  160. package/dist/internal/infra-analytics-runtime.mjs +4 -4
  161. package/dist/internal/metadata-image-runtime.cjs +3 -3
  162. package/dist/internal/metadata-image-runtime.mjs +2 -2
  163. package/dist/internal/native-server-fns.cjs +25 -0
  164. package/dist/internal/native-server-fns.d.mts +42 -0
  165. package/dist/internal/native-server-fns.d.ts +42 -0
  166. package/dist/internal/native-server-fns.mjs +25 -0
  167. package/dist/internal/product-telemetry-runtime.cjs +2 -2
  168. package/dist/internal/product-telemetry-runtime.mjs +1 -1
  169. package/dist/internal/production-node-env.cjs +2 -2
  170. package/dist/internal/production-node-env.mjs +1 -1
  171. package/dist/internal/production-runtime.cjs +16 -10
  172. package/dist/internal/production-runtime.d.mts +39 -12
  173. package/dist/internal/production-runtime.d.ts +39 -12
  174. package/dist/internal/production-runtime.mjs +15 -9
  175. package/dist/internal/react-cache.cjs +51 -0
  176. package/dist/internal/react-cache.d.mts +3 -0
  177. package/dist/internal/react-cache.d.ts +3 -0
  178. package/dist/internal/react-cache.mjs +51 -0
  179. package/dist/markdown.d.mts +2 -2
  180. package/dist/markdown.d.ts +2 -2
  181. package/dist/middleware.cjs +3 -3
  182. package/dist/middleware.d.mts +4 -4
  183. package/dist/middleware.d.ts +4 -4
  184. package/dist/middleware.mjs +2 -2
  185. package/dist/mobile.d.mts +10 -4
  186. package/dist/mobile.d.ts +10 -4
  187. package/dist/{modules-VHD7BELU.mjs → modules-KOKD4XS6.mjs} +2 -2
  188. package/dist/modules-QTP7WJPD.cjs +13 -0
  189. package/dist/native-server-fn-handler-GLRHAYWV.mjs +28 -0
  190. package/dist/native-server-fn-handler-J5MYRXN6.cjs +28 -0
  191. package/dist/native-specs-5OLED4MM.cjs +15 -0
  192. package/dist/{native-specs-BD7HOTMJ.mjs → native-specs-LDV6IZ4N.mjs} +1 -1
  193. package/dist/{native-tree-VWNW2MQ2.mjs → native-tree-AS5L3ID3.mjs} +2 -2
  194. package/dist/{native-tree-6G5O53O3.cjs → native-tree-Z2WYUJEV.cjs} +3 -3
  195. package/dist/native.cjs +1 -1
  196. package/dist/native.d.mts +5 -5
  197. package/dist/native.d.ts +5 -5
  198. package/dist/native.mjs +1 -1
  199. package/dist/{navigation-delegate.d-JXx40JzR.d.ts → navigation-delegate.d-BbUHRXxG.d.ts} +1 -1
  200. package/dist/{navigation-delegate.d-CnOTWOyi.d.mts → navigation-delegate.d-CSCm8ZxL.d.mts} +1 -1
  201. package/dist/navigation.d.mts +5 -5
  202. package/dist/navigation.d.ts +5 -5
  203. package/dist/{nitro-FLN6DRGJ.mjs → nitro-DD4QCA66.mjs} +5 -5
  204. package/dist/{nitro-HXAZZQKY.cjs → nitro-VRDX2H4M.cjs} +8 -8
  205. package/dist/plugin.cjs +19 -18
  206. package/dist/plugin.d.mts +5 -5
  207. package/dist/plugin.d.ts +5 -5
  208. package/dist/plugin.mjs +18 -17
  209. package/dist/{port-WOOQ3V56.mjs → port-UFUZL6RI.mjs} +2 -2
  210. package/dist/{port-C6GBH4C6.cjs → port-VTLHPZOI.cjs} +10 -10
  211. package/dist/{production-runtime.d-CP5s6RuY.d.mts → production-runtime.d-CcQiDko5.d.mts} +1 -1
  212. package/dist/{production-runtime.d-N-cE3pmy.d.ts → production-runtime.d-DgT24A0f.d.ts} +1 -1
  213. package/dist/{render-plan.d-DZ-qjjdG.d.mts → render-plan.d-BH9WF-JZ.d.mts} +1 -1
  214. package/dist/{render-plan.d-B9lAP3uX.d.ts → render-plan.d-CyrX6MDs.d.ts} +1 -1
  215. package/dist/renderer-client.d.mts +5 -5
  216. package/dist/renderer-client.d.ts +5 -5
  217. package/dist/{request.d-BiicaNxb.d.ts → request.d-BB8M8bcD.d.ts} +1 -1
  218. package/dist/{request.d-DV0oeUit.d.mts → request.d-CUrPnCW7.d.mts} +1 -1
  219. package/dist/request.d.mts +3 -3
  220. package/dist/request.d.ts +3 -3
  221. package/dist/{route-rendering.d-BrIKA51A.d.mts → route-rendering.d-CYxlzaFm.d.mts} +1 -1
  222. package/dist/{route-rendering.d-Iss0C7GR.d.ts → route-rendering.d-DYqZMIf4.d.ts} +1 -1
  223. package/dist/{router.d-mNTbOGV_.d.mts → router.d-7o24CD8u.d.mts} +1 -1
  224. package/dist/{router.d-DjGn_al7.d.ts → router.d-DaKo507j.d.ts} +1 -1
  225. package/dist/{routes.d-BKSjHuH9.d.ts → routes.d-BknKQcTu.d.ts} +7 -1
  226. package/dist/{routes.d-qd8Qf4LG.d.mts → routes.d-D1IrO9KK.d.mts} +7 -1
  227. package/dist/routes.d.mts +2 -2
  228. package/dist/routes.d.ts +2 -2
  229. package/dist/{rsc-pipeline-SVLBTY7H.cjs → rsc-pipeline-OF2I7PCX.cjs} +8 -8
  230. package/dist/{rsc-pipeline-WBLBDQXA.mjs → rsc-pipeline-RFLHDAKD.mjs} +7 -7
  231. package/dist/{runtime-DGUOWSMF.cjs → runtime-LBTK62AD.cjs} +70 -47
  232. package/dist/{runtime-HFZTVNFF.mjs → runtime-M6UJCSLA.mjs} +38 -15
  233. package/dist/{runtime.d-Bm_4hP5T.d.ts → runtime.d-CN73a-IL.d.ts} +1 -1
  234. package/dist/{runtime.d-BNVbojF1.d.mts → runtime.d-CcNuzhX6.d.mts} +1 -1
  235. package/dist/server-action-security.cjs +3 -3
  236. package/dist/server-action-security.mjs +2 -2
  237. package/dist/server-fn.cjs +4 -4
  238. package/dist/server-fn.mjs +3 -3
  239. package/dist/server-plugins.d.mts +3 -3
  240. package/dist/server-plugins.d.ts +3 -3
  241. package/dist/server-query.cjs +5 -5
  242. package/dist/server-query.mjs +4 -4
  243. package/dist/server.cjs +38 -37
  244. package/dist/server.d.mts +10 -10
  245. package/dist/server.d.ts +10 -10
  246. package/dist/server.mjs +23 -22
  247. package/dist/{spa-router.d-DHDoXxDE.d.mts → spa-router.d-CNi77LZm.d.mts} +2 -2
  248. package/dist/{spa-router.d-DAtnNoBe.d.ts → spa-router.d-Cvgf5QP4.d.ts} +2 -2
  249. package/dist/testing.cjs +6 -6
  250. package/dist/testing.d.mts +2 -2
  251. package/dist/testing.d.ts +2 -2
  252. package/dist/testing.mjs +4 -4
  253. package/dist/{utils.d-DwZ-KLSB.d.ts → utils.d-C3H-14_Y.d.ts} +1 -1
  254. package/dist/{utils.d-uKZcKJk4.d.mts → utils.d-D8VfzZYn.d.mts} +1 -1
  255. package/dist/version.cjs +2 -2
  256. package/dist/version.mjs +1 -1
  257. package/dist/vite.cjs +21 -18
  258. package/dist/vite.d.mts +5 -5
  259. package/dist/vite.d.ts +5 -5
  260. package/dist/vite.mjs +20 -17
  261. package/dist/workflows.cjs +3 -3
  262. package/dist/workflows.mjs +2 -2
  263. package/package.json +12 -2
  264. package/dist/modules-WT5D3AWY.cjs +0 -13
  265. package/dist/native-specs-IQQRJOOW.cjs +0 -15
@@ -5,12 +5,9 @@
5
5
  var _chunk65Y5SIBHcjs = require('./chunk-65Y5SIBH.cjs');
6
6
 
7
7
 
8
+ var _chunk5IQ2ERQAcjs = require('./chunk-5IQ2ERQA.cjs');
8
9
 
9
10
 
10
- var _chunkPIUTGRDIcjs = require('./chunk-PIUTGRDI.cjs');
11
-
12
-
13
- var _chunkA5BJKSZEcjs = require('./chunk-A5BJKSZE.cjs');
14
11
 
15
12
 
16
13
 
@@ -40,7 +37,7 @@ var _chunkA5BJKSZEcjs = require('./chunk-A5BJKSZE.cjs');
40
37
 
41
38
 
42
39
 
43
- var _chunkUYSTTPYJcjs = require('./chunk-UYSTTPYJ.cjs');
40
+ var _chunkGGNJAGGEcjs = require('./chunk-GGNJAGGE.cjs');
44
41
 
45
42
 
46
43
  var _chunkR53QDV6Tcjs = require('./chunk-R53QDV6T.cjs');
@@ -53,7 +50,7 @@ var _chunkAQLHD6HZcjs = require('./chunk-AQLHD6HZ.cjs');
53
50
 
54
51
 
55
52
 
56
- var _chunk3TL3AH25cjs = require('./chunk-3TL3AH25.cjs');
53
+ var _chunkX4K7TYN6cjs = require('./chunk-X4K7TYN6.cjs');
57
54
 
58
55
 
59
56
 
@@ -85,12 +82,17 @@ var _chunkSGBNF56Scjs = require('./chunk-SGBNF56S.cjs');
85
82
 
86
83
 
87
84
 
88
- var _chunkDPJ66FSIcjs = require('./chunk-DPJ66FSI.cjs');
85
+ var _chunkXX32BOMMcjs = require('./chunk-XX32BOMM.cjs');
89
86
 
90
87
 
91
88
  var _chunkQAS7KE7Jcjs = require('./chunk-QAS7KE7J.cjs');
92
89
 
93
90
 
91
+
92
+
93
+ var _chunkPIUTGRDIcjs = require('./chunk-PIUTGRDI.cjs');
94
+
95
+
94
96
  var _chunk7EPYN7GWcjs = require('./chunk-7EPYN7GW.cjs');
95
97
 
96
98
 
@@ -170,7 +172,7 @@ var _chunkX333W5KVcjs = require('./chunk-X333W5KV.cjs');
170
172
 
171
173
 
172
174
 
173
- var _chunkZP32GNJQcjs = require('./chunk-ZP32GNJQ.cjs');
175
+ var _chunkI32V5CZLcjs = require('./chunk-I32V5CZL.cjs');
174
176
 
175
177
 
176
178
  var _chunkLQNW3ABPcjs = require('./chunk-LQNW3ABP.cjs');
@@ -189,7 +191,7 @@ var _chunkKBGZ5FD6cjs = require('./chunk-KBGZ5FD6.cjs');
189
191
  var _chunkP2355C6Ecjs = require('./chunk-P2355C6E.cjs');
190
192
 
191
193
 
192
- var _chunkW2RZ73IUcjs = require('./chunk-W2RZ73IU.cjs');
194
+ var _chunkSYXPWJ7Ncjs = require('./chunk-SYXPWJ7N.cjs');
193
195
 
194
196
 
195
197
  var _chunkRVGLYMJMcjs = require('./chunk-RVGLYMJM.cjs');
@@ -199,7 +201,7 @@ var _chunkRVGLYMJMcjs = require('./chunk-RVGLYMJM.cjs');
199
201
  var _chunkKORZ6PREcjs = require('./chunk-KORZ6PRE.cjs');
200
202
 
201
203
 
202
- var _chunkCBKRS3M4cjs = require('./chunk-CBKRS3M4.cjs');
204
+ var _chunkZ7P2BTZ3cjs = require('./chunk-Z7P2BTZ3.cjs');
203
205
 
204
206
 
205
207
  var _chunkLRB5OVRTcjs = require('./chunk-LRB5OVRT.cjs');
@@ -247,10 +249,10 @@ var _chunk2OF5RPVUcjs = require('./chunk-2OF5RPVU.cjs');
247
249
 
248
250
 
249
251
 
250
- var _chunkLIFUPCXWcjs = require('./chunk-LIFUPCXW.cjs');
252
+ var _chunkCFG4QERRcjs = require('./chunk-CFG4QERR.cjs');
251
253
 
252
254
 
253
- var _chunk2FRLSDBTcjs = require('./chunk-2FRLSDBT.cjs');
255
+ var _chunkSM25ZC4Scjs = require('./chunk-SM25ZC4S.cjs');
254
256
 
255
257
 
256
258
  var _chunkPMJSG4JScjs = require('./chunk-PMJSG4JS.cjs');
@@ -287,7 +289,7 @@ var _chunkBTZ5O6VMcjs = require('./chunk-BTZ5O6VM.cjs');
287
289
  // src/form-actions-transform.ts
288
290
  var _crypto = require('crypto');
289
291
  var _compiler = require('@farm.js/islx/compiler');
290
- var _path = require('path'); var path2 = _interopRequireWildcard(_path); var path5 = _interopRequireWildcard(_path); var path3 = _interopRequireWildcard(_path);
292
+ var _path = require('path'); var path2 = _interopRequireWildcard(_path); var path6 = _interopRequireWildcard(_path); var path3 = _interopRequireWildcard(_path);
291
293
  function transformFarmFormActionModule(options) {
292
294
  const result = _compiler.transformActions.call(void 0, {
293
295
  code: options.code,
@@ -322,8 +324,13 @@ var VITE_DEFAULT_FS_DENY = [
322
324
  ".yarnrc.yml",
323
325
  "**/.git/**"
324
326
  ];
327
+ var FARM_DEV_FS_DENY = [
328
+ "**/.farm/!(client-references)/**",
329
+ "**/.farm/client-references?*/**",
330
+ "**/.farm/*"
331
+ ];
325
332
  function getFarmDevFsDeny(userDeny, options) {
326
- const deny = ["**/.farm/**"];
333
+ const deny = [...FARM_DEV_FS_DENY];
327
334
  const root = path2.resolve(options.root || process.cwd());
328
335
  const distDir = options.distDir ? path2.resolve(root, options.distDir) : void 0;
329
336
  const relativeDistDir = distDir ? path2.relative(root, distDir) : "";
@@ -678,6 +685,52 @@ async function createBlurDataURL(bytes) {
678
685
  }
679
686
  }
680
687
 
688
+ // src/vite.ts
689
+
690
+
691
+ // src/islands-react-cache-transform.ts
692
+
693
+ var _parseAst = require('rolldown/parseAst');
694
+ var FARM_REACT_CACHE_MODULE = "@farm.js/core/internal/react-cache";
695
+ function rewriteFarmReactCacheImport(code, file) {
696
+ if (!code.includes("cache") || !code.includes("react")) return null;
697
+ const extension = path2.default.extname(file).slice(1);
698
+ const lang = extension === "ts" || extension === "mts" || extension === "cts" ? "ts" : "tsx";
699
+ let program;
700
+ try {
701
+ program = _parseAst.parseAst.call(void 0, code, { lang });
702
+ } catch (e8) {
703
+ return null;
704
+ }
705
+ let output = code;
706
+ const declarations = (_nullishCoalesce(program.body, () => ( []))).filter(
707
+ (node) => node.type === "ImportDeclaration" && _optionalChain([node, 'access', _39 => _39.source, 'optionalAccess', _40 => _40.value]) === "react" && node.importKind !== "type"
708
+ );
709
+ let changed = false;
710
+ for (const node of [...declarations].sort((left, right) => right.start - left.start)) {
711
+ const specifiers = _nullishCoalesce(node.specifiers, () => ( []));
712
+ const caches = specifiers.filter(
713
+ (specifier) => specifier.type === "ImportSpecifier" && specifier.importKind !== "type" && (_nullishCoalesce(_optionalChain([specifier, 'access', _41 => _41.imported, 'optionalAccess', _42 => _42.name]), () => ( _optionalChain([specifier, 'access', _43 => _43.imported, 'optionalAccess', _44 => _44.value])))) === "cache"
714
+ );
715
+ if (caches.length === 0) continue;
716
+ const others = specifiers.filter((specifier) => !caches.includes(specifier));
717
+ const text = (specifier) => code.slice(specifier.start, specifier.end);
718
+ const defaults = others.filter((specifier) => specifier.type !== "ImportSpecifier");
719
+ const named = others.filter((specifier) => specifier.type === "ImportSpecifier");
720
+ const clause = [
721
+ ...defaults.map(text),
722
+ ...named.length > 0 ? [`{ ${named.map(text).join(", ")} }`] : []
723
+ ].join(", ");
724
+ const lines = [
725
+ ...clause ? [`import ${clause} from "react";`] : [],
726
+ `import { ${caches.map((specifier) => `cache as ${specifier.local.name}`).join(", ")} } from ${JSON.stringify(FARM_REACT_CACHE_MODULE)};`
727
+ ];
728
+ output = output.slice(0, node.start) + lines.join("\n") + output.slice(node.end);
729
+ changed = true;
730
+ }
731
+ return changed ? output : null;
732
+ }
733
+
681
734
  // src/navigation/page-data-error.ts
682
735
  function resolveFarmPageDataFailure(error) {
683
736
  if (_chunk7JUIK547cjs.isFarmNotFoundError.call(void 0, error)) {
@@ -720,13 +773,13 @@ function reportOpenAPIDevGenerationResult(spec, output = _chunkQMNWKQL4cjs.logge
720
773
  // src/vite.ts
721
774
  var SERVER_FN_TRANSFORM_PLUGIN = "@farm.js/plugin/rsc:server-fn-actions";
722
775
  function farmLlmsTxtGeneratedPaths(config) {
723
- const llms = _chunkMEQN6DDAcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([config, 'access', _39 => _39.agent, 'optionalAccess', _40 => _40.llmsTxt]));
776
+ const llms = _chunkMEQN6DDAcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([config, 'access', _45 => _45.agent, 'optionalAccess', _46 => _46.llmsTxt]));
724
777
  if (!llms.enabled) return [];
725
778
  return llms.full ? ["/llms.txt", "/llms-full.txt"] : ["/llms.txt"];
726
779
  }
727
780
  function farmAgentGeneratedPaths(config) {
728
- const crawlers = _chunkDZPR2W6Ucjs.resolveFarmAgentCrawlers.call(void 0, _optionalChain([config, 'access', _41 => _41.agent, 'optionalAccess', _42 => _42.crawlers]));
729
- const sitemap = _chunkDZPR2W6Ucjs.resolveFarmAgentSitemap.call(void 0, _optionalChain([config, 'access', _43 => _43.agent, 'optionalAccess', _44 => _44.sitemap]));
781
+ const crawlers = _chunkDZPR2W6Ucjs.resolveFarmAgentCrawlers.call(void 0, _optionalChain([config, 'access', _47 => _47.agent, 'optionalAccess', _48 => _48.crawlers]));
782
+ const sitemap = _chunkDZPR2W6Ucjs.resolveFarmAgentSitemap.call(void 0, _optionalChain([config, 'access', _49 => _49.agent, 'optionalAccess', _50 => _50.sitemap]));
730
783
  return [
731
784
  ...farmLlmsTxtGeneratedPaths(config),
732
785
  ...sitemap.enabled ? ["/sitemap.xml"] : [],
@@ -771,7 +824,7 @@ function loadFarmWorkflowsDevRuntime() {
771
824
  return import("./workflows.cjs");
772
825
  }
773
826
  function loadFarmDevtoolsSnapshotRuntime() {
774
- return import("./devtools-UF6JYHUN.cjs");
827
+ return import("./devtools-SVRSGPNC.cjs");
775
828
  }
776
829
  function loadFarmDevtoolsUIRuntime() {
777
830
  return import("./devtools-ui-SYRUXUA7.cjs");
@@ -784,7 +837,7 @@ function farmI18nClientBridgePlugin() {
784
837
  name: "farm:i18n-client-bridge",
785
838
  enforce: "pre",
786
839
  resolveId(id, _importer, options) {
787
- if (id === "@farm.js/core/i18n/server" && !_optionalChain([options, 'optionalAccess', _45 => _45.ssr])) {
840
+ if (id === "@farm.js/core/i18n/server" && !_optionalChain([options, 'optionalAccess', _51 => _51.ssr])) {
788
841
  return FARM_I18N_CLIENT_BRIDGE_ID;
789
842
  }
790
843
  return null;
@@ -796,6 +849,8 @@ function farmI18nClientBridgePlugin() {
796
849
  };
797
850
  }
798
851
  var FARM_SERVER_ONLY_ENTRIES = /* @__PURE__ */ new Set(["@farm.js/core/og"]);
852
+ var SERVER_ONLY_PACKAGE = "server-only";
853
+ var FARM_SERVER_ONLY_PACKAGE_ID = "\0farm:server-only";
799
854
  var FARM_PLATFORM_ENTRY = "@farm.js/core/platform";
800
855
  var FARM_PLATFORM_CLIENT_ID = "\0farm:platform-client";
801
856
  function createFarmPlatformClientModule(platform) {
@@ -813,20 +868,30 @@ function farmServerOnlyEntriesPlugin(options = {}) {
813
868
  enforce: "pre",
814
869
  config() {
815
870
  return {
816
- optimizeDeps: { rolldownOptions: { plugins: [_chunkNK2VWS7Pcjs.farmBrowserBuiltinsOptimizerPlugin.call(void 0, )] } }
871
+ optimizeDeps: { rolldownOptions: { plugins: [_chunkNK2VWS7Pcjs.farmBrowserBuiltinsOptimizerPlugin.call(void 0, )] } },
872
+ // Resolve `server-only` here rather than in Node, which would load its throwing build.
873
+ ssr: { noExternal: [SERVER_ONLY_PACKAGE] }
817
874
  };
818
875
  },
819
876
  configResolved(config) {
820
877
  root = config.root;
821
878
  },
822
879
  resolveId(id, importer, options2) {
823
- if (id === FARM_PLATFORM_ENTRY) return _optionalChain([options2, 'optionalAccess', _46 => _46.ssr]) ? null : FARM_PLATFORM_CLIENT_ID;
824
- if (!_optionalChain([options2, 'optionalAccess', _47 => _47.ssr]) && _module.isBuiltin.call(void 0, id)) {
880
+ if (id === FARM_PLATFORM_ENTRY) return _optionalChain([options2, 'optionalAccess', _52 => _52.ssr]) ? null : FARM_PLATFORM_CLIENT_ID;
881
+ if (id === SERVER_ONLY_PACKAGE) {
882
+ if (_optionalChain([options2, 'optionalAccess', _53 => _53.ssr]) || _optionalChain([options2, 'optionalAccess', _54 => _54.scan])) {
883
+ return FARM_SERVER_ONLY_PACKAGE_ID;
884
+ }
885
+ this.error(
886
+ `${_nullishCoalesce(importer, () => ( "A module"))} imports "server-only", so it must not reach the browser, but client code imports it. Move what the client needs out of that module, or call it from a server component, server function or API route.`
887
+ );
888
+ }
889
+ if (!_optionalChain([options2, 'optionalAccess', _55 => _55.ssr]) && _module.isBuiltin.call(void 0, id)) {
825
890
  return _chunkNK2VWS7Pcjs.resolveFarmBrowserBuiltin.call(void 0, this, id, importer, options2);
826
891
  }
827
892
  if (!FARM_SERVER_ONLY_ENTRIES.has(id)) return null;
828
893
  const importedBy = importer ? ` (imported by ${importer})` : "";
829
- if (!_optionalChain([options2, 'optionalAccess', _48 => _48.ssr])) {
894
+ if (!_optionalChain([options2, 'optionalAccess', _56 => _56.ssr])) {
830
895
  this.error(
831
896
  `${id} is server-only and cannot be imported into client code${importedBy}. Use it from an API route or another server module.`
832
897
  );
@@ -840,6 +905,7 @@ function farmServerOnlyEntriesPlugin(options = {}) {
840
905
  return null;
841
906
  },
842
907
  load(id) {
908
+ if (id === FARM_SERVER_ONLY_PACKAGE_ID) return "export {};";
843
909
  if (id === FARM_PLATFORM_CLIENT_ID) {
844
910
  return createFarmPlatformClientModule(_nullishCoalesce(options.platform, () => ( _chunkAQLHD6HZcjs.resolveFarmPlatform.call(void 0, ))));
845
911
  }
@@ -878,7 +944,7 @@ function renderFarmI18nStaticHead(requestPath, snapshot) {
878
944
  return `${_chunkO27PLNQZcjs.renderFarmLocaleAlternateLinks.call(void 0, requestPath, snapshot)}${runtime}`;
879
945
  }
880
946
  function getPublicEnvDefine(config) {
881
- const publicEnv = _optionalChain([config, 'access', _49 => _49.env, 'optionalAccess', _50 => _50.public]);
947
+ const publicEnv = _optionalChain([config, 'access', _57 => _57.env, 'optionalAccess', _58 => _58.public]);
882
948
  if (!isResolvedEnvScope(publicEnv)) {
883
949
  return {};
884
950
  }
@@ -917,7 +983,7 @@ function withFarmRequestTracing(handler, apiRuntime, resolveTraceUrl = (request)
917
983
  return;
918
984
  }
919
985
  if (res.headersSent) {
920
- _optionalChain([res, 'access', _51 => _51.destroy, 'optionalCall', _52 => _52(error instanceof Error ? error : new Error(String(error)))]);
986
+ _optionalChain([res, 'access', _59 => _59.destroy, 'optionalCall', _60 => _60(error instanceof Error ? error : new Error(String(error)))]);
921
987
  return;
922
988
  }
923
989
  res.statusCode = 500;
@@ -931,7 +997,7 @@ async function proxyFarmExternalRewrite(req, res, bodySizeLimit) {
931
997
  if (!destination || !/^https?:\/\//i.test(destination)) return false;
932
998
  let request = createRequestFromNodeRequest(req, new URL(destination));
933
999
  if (request.method !== "GET" && request.method !== "HEAD") {
934
- const body = await _chunkLIFUPCXWcjs.readNodeRequestBody.call(void 0, req, bodySizeLimit);
1000
+ const body = await _chunkCFG4QERRcjs.readNodeRequestBody.call(void 0, req, bodySizeLimit);
935
1001
  request = new Request(request, { body: toRequestBody(body) });
936
1002
  }
937
1003
  await _chunkYIHRZBD7cjs.sendWebResponse.call(void 0, res, await _chunkYIHRZBD7cjs.fetchFarmExternalRewrite.call(void 0, request));
@@ -1020,7 +1086,7 @@ function interceptFarmDevPageResponse(options) {
1020
1086
  const originalWrite = res.write.bind(res);
1021
1087
  const originalEnd = res.end.bind(res);
1022
1088
  const originalWriteHead = res.writeHead.bind(res);
1023
- const originalFlushHeaders = _optionalChain([res, 'access', _53 => _53.flushHeaders, 'optionalAccess', _54 => _54.bind, 'call', _55 => _55(res)]);
1089
+ const originalFlushHeaders = _optionalChain([res, 'access', _61 => _61.flushHeaders, 'optionalAccess', _62 => _62.bind, 'call', _63 => _63(res)]);
1024
1090
  let afterResponseCalled = false;
1025
1091
  let interceptedEnd = false;
1026
1092
  const htmlChunks = [];
@@ -1060,7 +1126,7 @@ function interceptFarmDevPageResponse(options) {
1060
1126
  const shouldBufferResponse = isHtmlResponse ? bufferPluginResponse : Boolean(runtimeSession && hasRuntimeAfterHook);
1061
1127
  if (shouldBufferResponse) {
1062
1128
  const callback = args.find((arg) => typeof arg === "function");
1063
- _optionalChain([callback, 'optionalCall', _56 => _56()]);
1129
+ _optionalChain([callback, 'optionalCall', _64 => _64()]);
1064
1130
  return true;
1065
1131
  }
1066
1132
  const writeResult = originalWrite(chunk, ...args);
@@ -1173,13 +1239,13 @@ function getEnvDefines(config, configEnv) {
1173
1239
  _chunkHEPJIKKQcjs.getPublicFarmImageConfig.call(void 0, _chunkHEPJIKKQcjs.resolveFarmImageConfig.call(void 0, config.images))
1174
1240
  )
1175
1241
  };
1176
- if (_optionalChain([configEnv, 'optionalAccess', _57 => _57.isSsrBuild])) {
1242
+ if (_optionalChain([configEnv, 'optionalAccess', _65 => _65.isSsrBuild])) {
1177
1243
  defines.__FARM_ENV__ = JSON.stringify(_chunk3EIPOTZVcjs.createBundledEnv.call(void 0, getFullEnvDefine(config)));
1178
1244
  }
1179
1245
  return defines;
1180
1246
  }
1181
1247
  function getFarmAPIBaseURLDefine(config) {
1182
- const baseURL = _optionalChain([config, 'access', _58 => _58.api, 'optionalAccess', _59 => _59.baseURL]);
1248
+ const baseURL = _optionalChain([config, 'access', _66 => _66.api, 'optionalAccess', _67 => _67.baseURL]);
1183
1249
  return typeof baseURL === "string" && baseURL ? baseURL : _chunkPMJSG4JScjs.DEFAULT_FARM_API_BASE_PATH;
1184
1250
  }
1185
1251
  function isResolvedEnvScope(value) {
@@ -1199,20 +1265,20 @@ function fileContainsProgrammaticPageRoute(file) {
1199
1265
  }
1200
1266
  try {
1201
1267
  return _chunkE7QOEV5Zcjs.scanProgrammaticPagePaths.call(void 0, fs2.readFileSync(file, "utf8")).length > 0;
1202
- } catch (e8) {
1268
+ } catch (e9) {
1203
1269
  return false;
1204
1270
  }
1205
1271
  }
1206
1272
  function rewriteEarlySsrRelativeImports(options) {
1207
1273
  const cleanId = options.id.split("?", 1)[0];
1208
- if (!path5.isAbsolute(cleanId) || cleanId.replace(/\\/g, "/").includes("/node_modules/")) {
1274
+ if (!path6.isAbsolute(cleanId) || cleanId.replace(/\\/g, "/").includes("/node_modules/")) {
1209
1275
  return null;
1210
1276
  }
1211
1277
  const replacements = [];
1212
1278
  let ast;
1213
1279
  try {
1214
1280
  ast = options.parse(options.code);
1215
- } catch (e9) {
1281
+ } catch (e10) {
1216
1282
  return null;
1217
1283
  }
1218
1284
  walkModuleAst(ast, (node) => {
@@ -1225,7 +1291,7 @@ function rewriteEarlySsrRelativeImports(options) {
1225
1291
  const suffixIndex = source.value.search(/[?#]/);
1226
1292
  const sourcePath = suffixIndex === -1 ? source.value : source.value.slice(0, suffixIndex);
1227
1293
  const suffix = suffixIndex === -1 ? "" : source.value.slice(suffixIndex);
1228
- const resolvedPath = path5.resolve(path5.dirname(cleanId), sourcePath);
1294
+ const resolvedPath = path6.resolve(path6.dirname(cleanId), sourcePath);
1229
1295
  const moduleId = _chunkQMNWKQL4cjs.toViteModuleId.call(void 0, resolvedPath, options.root);
1230
1296
  const specifier = moduleId.startsWith("/@fs/") ? _chunkQMNWKQL4cjs.toPosixPath.call(void 0, resolvedPath) : moduleId;
1231
1297
  replacements.push({
@@ -1242,10 +1308,23 @@ function rewriteEarlySsrRelativeImports(options) {
1242
1308
  return output;
1243
1309
  }
1244
1310
  function transformIsolatedClientBoundaryModule(options) {
1311
+ if (options.slots) {
1312
+ try {
1313
+ const rewritten = _compiler.rewriteFormStatusImports.call(void 0, {
1314
+ code: options.code,
1315
+ id: options.moduleReference,
1316
+ parse: options.parse,
1317
+ from: "@farm.js/core/internal/islx-react"
1318
+ });
1319
+ if (rewritten) options = { ...options, code: rewritten.code };
1320
+ } catch (e11) {
1321
+ return null;
1322
+ }
1323
+ }
1245
1324
  let ast;
1246
1325
  try {
1247
1326
  ast = options.parse(options.code);
1248
- } catch (e10) {
1327
+ } catch (e12) {
1249
1328
  return null;
1250
1329
  }
1251
1330
  const body = Array.isArray(ast.body) ? ast.body : [];
@@ -1267,9 +1346,9 @@ function transformIsolatedClientBoundaryModule(options) {
1267
1346
  transformedExports++;
1268
1347
  };
1269
1348
  for (const node of body) {
1270
- if (_optionalChain([node, 'optionalAccess', _60 => _60.type]) === "ExportDefaultDeclaration" && node.declaration) {
1349
+ if (_optionalChain([node, 'optionalAccess', _68 => _68.type]) === "ExportDefaultDeclaration" && node.declaration) {
1271
1350
  const declaration2 = node.declaration;
1272
- if ((declaration2.type === "FunctionDeclaration" || declaration2.type === "ClassDeclaration") && _optionalChain([declaration2, 'access', _61 => _61.id, 'optionalAccess', _62 => _62.name])) {
1351
+ if ((declaration2.type === "FunctionDeclaration" || declaration2.type === "ClassDeclaration") && _optionalChain([declaration2, 'access', _69 => _69.id, 'optionalAccess', _70 => _70.name])) {
1273
1352
  replacements.push({
1274
1353
  start: node.start,
1275
1354
  end: node.end,
@@ -1287,11 +1366,11 @@ function transformIsolatedClientBoundaryModule(options) {
1287
1366
  }
1288
1367
  continue;
1289
1368
  }
1290
- if (_optionalChain([node, 'optionalAccess', _63 => _63.type]) === "ExportNamedDeclaration" && !node.declaration && node.exportKind !== "type") {
1369
+ if (_optionalChain([node, 'optionalAccess', _71 => _71.type]) === "ExportNamedDeclaration" && !node.declaration && node.exportKind !== "type") {
1291
1370
  const specifiers = (node.specifiers || []).filter(
1292
1371
  (specifier) => specifier.type === "ExportSpecifier" && specifier.exportKind !== "type"
1293
1372
  );
1294
- const specifierName = (name) => _nullishCoalesce(_optionalChain([name, 'optionalAccess', _64 => _64.name]), () => ( String(_nullishCoalesce(_optionalChain([name, 'optionalAccess', _65 => _65.value]), () => ( "")))));
1373
+ const specifierName = (name) => _nullishCoalesce(_optionalChain([name, 'optionalAccess', _72 => _72.name]), () => ( String(_nullishCoalesce(_optionalChain([name, 'optionalAccess', _73 => _73.value]), () => ( "")))));
1295
1374
  const isComponentExport = (specifier) => {
1296
1375
  const exported = specifierName(specifier.exported);
1297
1376
  return exported === "default" || /^[A-Z]/.test(exported);
@@ -1318,14 +1397,14 @@ function transformIsolatedClientBoundaryModule(options) {
1318
1397
  if (kept.length > 0) wrapperStatements.push(`export { ${kept.join(", ")} };`);
1319
1398
  continue;
1320
1399
  }
1321
- if (_optionalChain([node, 'optionalAccess', _66 => _66.type]) !== "ExportNamedDeclaration" || !node.declaration) continue;
1400
+ if (_optionalChain([node, 'optionalAccess', _74 => _74.type]) !== "ExportNamedDeclaration" || !node.declaration) continue;
1322
1401
  const declaration = node.declaration;
1323
1402
  const declaredNames = [];
1324
- if ((declaration.type === "FunctionDeclaration" || declaration.type === "ClassDeclaration") && _optionalChain([declaration, 'access', _67 => _67.id, 'optionalAccess', _68 => _68.name])) {
1403
+ if ((declaration.type === "FunctionDeclaration" || declaration.type === "ClassDeclaration") && _optionalChain([declaration, 'access', _75 => _75.id, 'optionalAccess', _76 => _76.name])) {
1325
1404
  declaredNames.push(declaration.id.name);
1326
1405
  } else if (declaration.type === "VariableDeclaration") {
1327
1406
  for (const declarator of declaration.declarations || []) {
1328
- if (_optionalChain([declarator, 'access', _69 => _69.id, 'optionalAccess', _70 => _70.type]) === "Identifier") declaredNames.push(declarator.id.name);
1407
+ if (_optionalChain([declarator, 'access', _77 => _77.id, 'optionalAccess', _78 => _78.type]) === "Identifier") declaredNames.push(declarator.id.name);
1329
1408
  }
1330
1409
  }
1331
1410
  const componentNames = declaredNames.filter((name) => /^[A-Z]/.test(name));
@@ -1386,10 +1465,10 @@ function warnClientBoundaryOnce(context, id, code, config) {
1386
1465
  let program;
1387
1466
  try {
1388
1467
  program = context.parse(code);
1389
- } catch (e11) {
1468
+ } catch (e13) {
1390
1469
  return;
1391
1470
  }
1392
- const publicKeys = new Set(Object.keys(_nullishCoalesce(_optionalChain([config, 'access', _71 => _71.env, 'optionalAccess', _72 => _72.public]), () => ( {}))));
1471
+ const publicKeys = new Set(Object.keys(_nullishCoalesce(_optionalChain([config, 'access', _79 => _79.env, 'optionalAccess', _80 => _80.public]), () => ( {}))));
1393
1472
  const findings = analyzeClientBoundary(program, publicKeys);
1394
1473
  if (findings.envKeys.length === 0 && findings.publicEnvKeys.length === 0 && findings.builtinImports.length === 0) {
1395
1474
  return;
@@ -1409,7 +1488,7 @@ function hasViteAlias(alias, find) {
1409
1488
  }
1410
1489
  function farmPlugin(options = {}, initialPluginManager) {
1411
1490
  const imageImports = farmImageImportsPlugin();
1412
- const fontImports = _chunkUYSTTPYJcjs.farmFontImportsPlugin.call(void 0, {
1491
+ const fontImports = _chunkGGNJAGGEcjs.farmFontImportsPlugin.call(void 0, {
1413
1492
  root: options.root,
1414
1493
  basePath: options.basePath,
1415
1494
  publicDir: options.publicDir
@@ -1417,8 +1496,8 @@ function farmPlugin(options = {}, initialPluginManager) {
1417
1496
  let farmApp;
1418
1497
  let serverFnTransformActive = false;
1419
1498
  const islandsServerFns = () => {
1420
- const config = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _73 => _73.getConfig, 'call', _74 => _74()]), () => ( options));
1421
- return _optionalChain([config, 'access', _75 => _75.experimental, 'optionalAccess', _76 => _76.serverActions]) === true && _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _77 => _77.experimental, 'optionalAccess', _78 => _78.serverComponents])) === "islands";
1499
+ const config = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _81 => _81.getConfig, 'call', _82 => _82()]), () => ( options));
1500
+ return _optionalChain([config, 'access', _83 => _83.experimental, 'optionalAccess', _84 => _84.serverActions]) === true && _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _85 => _85.experimental, 'optionalAccess', _86 => _86.serverComponents])) === "islands";
1422
1501
  };
1423
1502
  let reactRefreshActive = false;
1424
1503
  let server;
@@ -1443,14 +1522,14 @@ function farmPlugin(options = {}, initialPluginManager) {
1443
1522
  ].join(" ");
1444
1523
  console.log(log);
1445
1524
  };
1446
- const getProgrammaticClientRoutes = () => _nullishCoalesce(options.programmaticClientRoutes, () => ( _optionalChain([farmApp, 'optionalAccess', _79 => _79.getRouteManager, 'call', _80 => _80(), 'access', _81 => _81.getProgrammaticClientRoutes, 'call', _82 => _82()])));
1525
+ const getProgrammaticClientRoutes = () => _nullishCoalesce(options.programmaticClientRoutes, () => ( _optionalChain([farmApp, 'optionalAccess', _87 => _87.getRouteManager, 'call', _88 => _88(), 'access', _89 => _89.getProgrammaticClientRoutes, 'call', _90 => _90()])));
1447
1526
  return {
1448
1527
  name: "farm",
1449
1528
  api: { getProgrammaticClientRoutes },
1450
1529
  config(userConfig, configEnv) {
1451
1530
  isBuild = configEnv.command === "build";
1452
1531
  const layerAliases = _chunk5Y2P454Ocjs.getFarmLayerAliases.call(void 0, options.layers);
1453
- const sourceAlias = hasViteAlias(_optionalChain([userConfig, 'access', _83 => _83.resolve, 'optionalAccess', _84 => _84.alias]), "@") ? {} : _chunkUYSTTPYJcjs.createFarmSourceAlias.call(void 0, options.root || process.cwd(), options.srcDir);
1532
+ const sourceAlias = hasViteAlias(_optionalChain([userConfig, 'access', _91 => _91.resolve, 'optionalAccess', _92 => _92.alias]), "@") ? {} : _chunkGGNJAGGEcjs.createFarmSourceAlias.call(void 0, options.root || process.cwd(), options.srcDir);
1454
1533
  const layerRoots = (_nullishCoalesce(options.layers, () => ( []))).map((layer) => layer.root);
1455
1534
  return {
1456
1535
  // Honor Farm's publicDir so the dev server serves the same static
@@ -1465,8 +1544,8 @@ function farmPlugin(options = {}, initialPluginManager) {
1465
1544
  },
1466
1545
  server: {
1467
1546
  fs: {
1468
- ...layerRoots.length ? { allow: [path5.resolve(options.root || process.cwd()), ...layerRoots] } : {},
1469
- deny: getFarmDevFsDeny(_optionalChain([userConfig, 'access', _85 => _85.server, 'optionalAccess', _86 => _86.fs, 'optionalAccess', _87 => _87.deny]), options)
1547
+ ...layerRoots.length ? { allow: [path6.resolve(options.root || process.cwd()), ...layerRoots] } : {},
1548
+ deny: getFarmDevFsDeny(_optionalChain([userConfig, 'access', _93 => _93.server, 'optionalAccess', _94 => _94.fs, 'optionalAccess', _95 => _95.deny]), options)
1470
1549
  }
1471
1550
  }
1472
1551
  };
@@ -1479,7 +1558,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1479
1558
  (plugin) => plugin.name === SERVER_FN_TRANSFORM_PLUGIN
1480
1559
  );
1481
1560
  reactRefreshActive = _chunk65Y5SIBHcjs.isFarmReactRefreshActive.call(void 0, config);
1482
- if (_optionalChain([options, 'access', _88 => _88.experimental, 'optionalAccess', _89 => _89.serverActions]) === true && !serverFnTransformActive && !islandsServerFns()) {
1561
+ if (_optionalChain([options, 'access', _96 => _96.experimental, 'optionalAccess', _97 => _97.serverActions]) === true && !serverFnTransformActive && !islandsServerFns()) {
1483
1562
  _chunkQMNWKQL4cjs.logger.warn(
1484
1563
  "experimental.serverActions has no effect without @farm.js/plugin/rsc in the Vite plugins. Server functions stay server-only, and importing one from client code is a build error."
1485
1564
  );
@@ -1488,7 +1567,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1488
1567
  async configureServer(viteServer) {
1489
1568
  viteServer.middlewares.use(
1490
1569
  createFarmDevPreviewGuard(viteServer, {
1491
- getSourceRoots: () => _chunk5Y2P454Ocjs.getFarmSourceRoots.call(void 0, _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _90 => _90.getConfig, 'call', _91 => _91()]), () => ( options)))
1570
+ getSourceRoots: () => _chunk5Y2P454Ocjs.getFarmSourceRoots.call(void 0, _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _98 => _98.getConfig, 'call', _99 => _99()]), () => ( options)))
1492
1571
  })
1493
1572
  );
1494
1573
  if (typeof fontImports.configureServer === "function") {
@@ -1500,10 +1579,10 @@ function farmPlugin(options = {}, initialPluginManager) {
1500
1579
  if (!pm) return;
1501
1580
  try {
1502
1581
  await pm.runHookParallel("onError", { phase, error, meta });
1503
- } catch (e12) {
1582
+ } catch (e14) {
1504
1583
  }
1505
1584
  };
1506
- farmApp = new (0, _chunkUYSTTPYJcjs.FarmApp)(
1585
+ farmApp = new (0, _chunkGGNJAGGEcjs.FarmApp)(
1507
1586
  {
1508
1587
  ...options,
1509
1588
  root: resolveDevelopmentRoot(options.root, server.config.root)
@@ -1513,7 +1592,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1513
1592
  await farmApp.initialize();
1514
1593
  const farmConfig = farmApp.getConfig();
1515
1594
  let farmAppPackages;
1516
- if (_optionalChain([farmConfig, 'access', _92 => _92.agent, 'optionalAccess', _93 => _93.noindexPreviews])) {
1595
+ if (_optionalChain([farmConfig, 'access', _100 => _100.agent, 'optionalAccess', _101 => _101.noindexPreviews])) {
1517
1596
  server.middlewares.use((_req, res, next) => {
1518
1597
  if (_chunkSGBNF56Scjs.isFarmPreviewDeploymentEnvironment.call(void 0, process.env)) {
1519
1598
  res.setHeader("X-Robots-Tag", _chunkDZPR2W6Ucjs.FARM_PREVIEW_ROBOTS_TAG);
@@ -1523,7 +1602,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1523
1602
  }
1524
1603
  const apiServerBasePath = _chunk2OF5RPVUcjs.resolveFarmAPIServerBasePath.call(void 0, farmConfig.api);
1525
1604
  const devBuiltInRoutePaths = new Set(
1526
- _chunkDPJ66FSIcjs.listFarmBuiltInRoutePaths.call(void 0, {
1605
+ _chunkXX32BOMMcjs.listFarmBuiltInRoutePaths.call(void 0, {
1527
1606
  agent: {
1528
1607
  apiCatalog: true,
1529
1608
  mcp: true,
@@ -1534,18 +1613,18 @@ function farmPlugin(options = {}, initialPluginManager) {
1534
1613
  openapi: options.openapi
1535
1614
  })
1536
1615
  );
1537
- const serverConfig = _chunkLIFUPCXWcjs.resolveFarmServerConfig.call(void 0, farmConfig.server);
1616
+ const serverConfig = _chunkCFG4QERRcjs.resolveFarmServerConfig.call(void 0, farmConfig.server);
1538
1617
  globalThis.__FARM_IMAGE_CONFIG__ = _chunkHEPJIKKQcjs.getPublicFarmImageConfig.call(void 0, farmConfig.images);
1539
1618
  let imageHandler = null;
1540
1619
  if (farmConfig.images.provider !== "none") {
1541
1620
  const { createNodeImageFetcher, createNodeImageUrlValidator, createSharpImageTransformer } = await import("./image/sharp.cjs");
1542
- imageHandler = _chunkA5BJKSZEcjs.createFarmImageHandler.call(void 0, farmConfig.images, {
1621
+ imageHandler = _chunk5IQ2ERQAcjs.createFarmImageHandler.call(void 0, farmConfig.images, {
1543
1622
  transform: createSharpImageTransformer(),
1544
1623
  fetchRemote: createNodeImageFetcher(farmConfig.images),
1545
1624
  validateRemoteUrl: createNodeImageUrlValidator(farmConfig.images),
1546
1625
  // Vite owns this address. Unlike request.url, it cannot be replaced by
1547
1626
  // a caller-controlled Host header.
1548
- trustedLocalOrigin: () => _optionalChain([server, 'access', _94 => _94.resolvedUrls, 'optionalAccess', _95 => _95.local, 'access', _96 => _96[0]]),
1627
+ trustedLocalOrigin: () => _optionalChain([server, 'access', _102 => _102.resolvedUrls, 'optionalAccess', _103 => _103.local, 'access', _104 => _104[0]]),
1549
1628
  onError(error) {
1550
1629
  _chunkQMNWKQL4cjs.logger.error(
1551
1630
  `Image optimization failed: ${error instanceof Error ? error.message : String(error)}`
@@ -1554,7 +1633,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1554
1633
  });
1555
1634
  }
1556
1635
  const sourceRoots = _chunk5Y2P454Ocjs.getFarmSourceRoots.call(void 0, farmConfig);
1557
- server.watcher.add(sourceRoots.map((source) => path5.join(source.root, source.srcDir)));
1636
+ server.watcher.add(sourceRoots.map((source) => path6.join(source.root, source.srcDir)));
1558
1637
  if (farmConfig.i18n.enabled) {
1559
1638
  server.watcher.add(
1560
1639
  farmConfig.i18n.locales.map(
@@ -1565,15 +1644,15 @@ function farmPlugin(options = {}, initialPluginManager) {
1565
1644
  const workflowConfig = farmConfig.workflows;
1566
1645
  const farmDocsDevRuntime = farmConfig.docs.enabled ? await loadFarmDocsDevRuntime() : null;
1567
1646
  const getExtraRouteTypes = () => [
1568
- ..._optionalChain([options, 'access', _97 => _97.openapi, 'optionalAccess', _98 => _98.enabled]) && options.openapi.route ? [options.openapi.route] : [],
1569
- ..._nullishCoalesce(_optionalChain([farmDocsDevRuntime, 'optionalAccess', _99 => _99.getFarmDocsRouteTypeEntries, 'call', _100 => _100(farmConfig.docs)]), () => ( []))
1647
+ ..._optionalChain([options, 'access', _105 => _105.openapi, 'optionalAccess', _106 => _106.enabled]) && options.openapi.route ? [options.openapi.route] : [],
1648
+ ..._nullishCoalesce(_optionalChain([farmDocsDevRuntime, 'optionalAccess', _107 => _107.getFarmDocsRouteTypeEntries, 'call', _108 => _108(farmConfig.docs)]), () => ( []))
1570
1649
  ];
1571
1650
  const appDirSlugs = sourceRoots.map(
1572
- (source) => path5.join(source.root, source.srcDir, "app").replace(/\\/g, "/")
1651
+ (source) => path6.join(source.root, source.srcDir, "app").replace(/\\/g, "/")
1573
1652
  );
1574
1653
  const generateTypeArtifacts = async (reason, selection = ALL_TYPE_ARTIFACTS, log = false) => {
1575
1654
  try {
1576
- const result = await _chunk3TL3AH25cjs.generateFarmTypeArtifacts.call(void 0, {
1655
+ const result = await _chunkX4K7TYN6cjs.generateFarmTypeArtifacts.call(void 0, {
1577
1656
  root: farmConfig.root,
1578
1657
  srcDir: farmConfig.srcDir,
1579
1658
  layers: farmConfig.layers,
@@ -1610,10 +1689,10 @@ function farmPlugin(options = {}, initialPluginManager) {
1610
1689
  };
1611
1690
  await generateTypeArtifacts("startup");
1612
1691
  const srcDirSlugs = sourceRoots.map(
1613
- (source) => path5.join(source.root, source.srcDir).replace(/\\/g, "/")
1692
+ (source) => path6.join(source.root, source.srcDir).replace(/\\/g, "/")
1614
1693
  );
1615
1694
  const layerConfigFiles = new Set(
1616
- farmConfig.layers.map((layer) => _optionalChain([layer, 'access', _101 => _101.configFile, 'optionalAccess', _102 => _102.replace, 'call', _103 => _103(/\\/g, "/")])).filter((file) => Boolean(file))
1695
+ farmConfig.layers.map((layer) => _optionalChain([layer, 'access', _109 => _109.configFile, 'optionalAccess', _110 => _110.replace, 'call', _111 => _111(/\\/g, "/")])).filter((file) => Boolean(file))
1617
1696
  );
1618
1697
  const routeModuleExtensions = /* @__PURE__ */ new Set([
1619
1698
  ..._chunkRD623KW4cjs.resolveFarmComponentExtensions.call(void 0, farmConfig.renderer.componentExtensions),
@@ -1692,7 +1771,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1692
1771
  scheduleTypeArtifactGen(file, ev, typeArtifacts);
1693
1772
  }
1694
1773
  if (isI18nCatalogFile(file)) {
1695
- _optionalChain([farmApp, 'optionalAccess', _104 => _104.getI18nRuntime, 'call', _105 => _105(), 'access', _106 => _106.reload, 'call', _107 => _107(), 'access', _108 => _108.then, 'call', _109 => _109(() => server.ws.send({ type: "full-reload", path: "*" })), 'access', _110 => _110.catch, 'call', _111 => _111((error) => _chunkQMNWKQL4cjs.logger.warn(`i18n catalog reload failed: ${error.message}`))]);
1774
+ _optionalChain([farmApp, 'optionalAccess', _112 => _112.getI18nRuntime, 'call', _113 => _113(), 'access', _114 => _114.reload, 'call', _115 => _115(), 'access', _116 => _116.then, 'call', _117 => _117(() => server.ws.send({ type: "full-reload", path: "*" })), 'access', _118 => _118.catch, 'call', _119 => _119((error) => _chunkQMNWKQL4cjs.logger.warn(`i18n catalog reload failed: ${error.message}`))]);
1696
1775
  }
1697
1776
  const isRouteRefreshEvent = (ev !== "change" || isStaticMetadataImageFile(file)) && (isAppRuntimeFile(file) || isProgrammaticRouteFile(file) || isProgrammaticRouteSourceFile(file) && (ev === "unlink" || fileContainsProgrammaticPageRoute(file)));
1698
1777
  if (isRouteRefreshEvent) {
@@ -1705,8 +1784,8 @@ function farmPlugin(options = {}, initialPluginManager) {
1705
1784
  const reloadsMiddleware = pendingRouteRefreshIncludesMiddleware;
1706
1785
  pendingRouteRefreshIncludesMiddleware = false;
1707
1786
  Promise.all([
1708
- _optionalChain([refreshRouteDiscovery, 'optionalCall', _112 => _112(`${ev} ${file}`)]),
1709
- reloadsMiddleware ? _optionalChain([middlewareManager, 'optionalAccess', _113 => _113.reload, 'call', _114 => _114()]) : void 0
1787
+ _optionalChain([refreshRouteDiscovery, 'optionalCall', _120 => _120(`${ev} ${file}`)]),
1788
+ reloadsMiddleware ? _optionalChain([middlewareManager, 'optionalAccess', _121 => _121.reload, 'call', _122 => _122()]) : void 0
1710
1789
  ]).then(() => server.ws.send({ type: "full-reload", path: "*" })).catch((error) => _chunkQMNWKQL4cjs.logger.warn(`Route refresh failed: ${error.message}`));
1711
1790
  }, 50);
1712
1791
  }
@@ -1741,7 +1820,18 @@ function farmPlugin(options = {}, initialPluginManager) {
1741
1820
  });
1742
1821
  }
1743
1822
  const dispatchToDevServer = _chunkBNH53KOTcjs.createFarmDevServerDispatch.call(void 0, server);
1744
- apiRouteManager = new (0, _chunkW2RZ73IUcjs.APIRouteManager)(appDirs, server, {
1823
+ if (options.mobileClient) {
1824
+ const { FARM_DEV_SERVER_MODULE_LOADER } = await import("./internal/native-server-fns.cjs");
1825
+ const load = (file) => _chunkJYNNIGQOcjs.loadFarmDevModule.call(void 0, server, file);
1826
+ globalThis[FARM_DEV_SERVER_MODULE_LOADER] = load;
1827
+ _optionalChain([server, 'access', _123 => _123.httpServer, 'optionalAccess', _124 => _124.once, 'call', _125 => _125("close", () => {
1828
+ const globals = globalThis;
1829
+ if (globals[FARM_DEV_SERVER_MODULE_LOADER] === load) {
1830
+ delete globals[FARM_DEV_SERVER_MODULE_LOADER];
1831
+ }
1832
+ })]);
1833
+ }
1834
+ apiRouteManager = new (0, _chunkSYXPWJ7Ncjs.APIRouteManager)(appDirs, server, {
1745
1835
  plugins: farmConfig.plugins,
1746
1836
  i18n: farmApp.getI18nRuntime(),
1747
1837
  bodySizeLimit: serverConfig.bodySizeLimit,
@@ -1758,7 +1848,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1758
1848
  farmApp.getServerRenderer().setAPIRouteLookup((routePath) => apiRouteManager.getRoutes().has(routePath));
1759
1849
  let discoveredWorkflows = [];
1760
1850
  const hasWorkflowDirectory = workflowConfig.enabled && workflowConfig.dirs.some(
1761
- (dir) => fs2.existsSync(path5.isAbsolute(dir) ? dir : path5.join(farmConfig.root, dir))
1851
+ (dir) => fs2.existsSync(path6.isAbsolute(dir) ? dir : path6.join(farmConfig.root, dir))
1762
1852
  );
1763
1853
  if (hasWorkflowDirectory) {
1764
1854
  const { createFarmWorkflowRequestHandler, discoverFarmWorkflows } = await loadFarmWorkflowsDevRuntime();
@@ -1808,11 +1898,11 @@ function farmPlugin(options = {}, initialPluginManager) {
1808
1898
  });
1809
1899
  }
1810
1900
  }
1811
- if (_optionalChain([options, 'access', _115 => _115.openapi, 'optionalAccess', _116 => _116.enabled])) {
1901
+ if (_optionalChain([options, 'access', _126 => _126.openapi, 'optionalAccess', _127 => _127.enabled])) {
1812
1902
  const { OpenAPIManager } = await loadFarmOpenAPIDevRuntime();
1813
1903
  openAPIManager = new OpenAPIManager(appDirs, options.openapi, {
1814
1904
  mode: "development",
1815
- apiBaseURL: typeof _optionalChain([options, 'access', _117 => _117.api, 'optionalAccess', _118 => _118.baseURL]) === "string" ? options.api.baseURL : void 0
1905
+ apiBaseURL: typeof _optionalChain([options, 'access', _128 => _128.api, 'optionalAccess', _129 => _129.baseURL]) === "string" ? options.api.baseURL : void 0
1816
1906
  });
1817
1907
  const spec = await openAPIManager.generateSpec();
1818
1908
  reportOpenAPIDevGenerationResult(spec);
@@ -1854,19 +1944,19 @@ function farmPlugin(options = {}, initialPluginManager) {
1854
1944
  clientEntry: "/@farm/client.js",
1855
1945
  resolveLayoutFonts: resolveDocsLayoutFonts,
1856
1946
  fontStylesheetHref: "/@farm/fonts.css",
1857
- globalStylesheetHref: _chunkUYSTTPYJcjs.resolveDevGlobalStylesheetHref.call(void 0,
1947
+ globalStylesheetHref: _chunkGGNJAGGEcjs.resolveDevGlobalStylesheetHref.call(void 0,
1858
1948
  farmConfig.root,
1859
1949
  farmConfig.srcDir
1860
1950
  ),
1861
1951
  loadModule: async (specifier) => {
1862
1952
  const resolved = await server.environments.ssr.pluginContainer.resolveId(specifier);
1863
- if (specifier === _optionalChain([farmConfig, 'access', _119 => _119.docs, 'access', _120 => _120.adapter, 'optionalAccess', _121 => _121.server]) && _optionalChain([resolved, 'optionalAccess', _122 => _122.id])) {
1953
+ if (specifier === _optionalChain([farmConfig, 'access', _130 => _130.docs, 'access', _131 => _131.adapter, 'optionalAccess', _132 => _132.server]) && _optionalChain([resolved, 'optionalAccess', _133 => _133.id])) {
1864
1954
  return import(
1865
1955
  /* @vite-ignore */
1866
1956
  _url.pathToFileURL.call(void 0, resolved.id).href
1867
1957
  );
1868
1958
  }
1869
- return _chunkJYNNIGQOcjs.loadFarmDevModule.call(void 0, server, _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _123 => _123.id]), () => ( specifier)));
1959
+ return _chunkJYNNIGQOcjs.loadFarmDevModule.call(void 0, server, _nullishCoalesce(_optionalChain([resolved, 'optionalAccess', _134 => _134.id]), () => ( specifier)));
1870
1960
  },
1871
1961
  registerMCPServer: (mcpServer) => {
1872
1962
  const dispose = _chunkLRB5OVRTcjs.registerFarmMCPServer.call(void 0, mcpServer);
@@ -1884,21 +1974,21 @@ function farmPlugin(options = {}, initialPluginManager) {
1884
1974
  fontAssets: _chunkERMUL73Lcjs.toFarmDocsPublicFontAssets.call(void 0, farmDocsFontAssetList),
1885
1975
  resolveLayoutFonts: resolveDocsLayoutFonts,
1886
1976
  fontStylesheetHref: "/@farm/fonts.css",
1887
- globalStylesheetHref: _chunkUYSTTPYJcjs.resolveDevGlobalStylesheetHref.call(void 0,
1977
+ globalStylesheetHref: _chunkGGNJAGGEcjs.resolveDevGlobalStylesheetHref.call(void 0,
1888
1978
  farmConfig.root,
1889
1979
  farmConfig.srcDir
1890
1980
  ),
1891
1981
  isPathGuarded: isFarmDocsPathGuarded
1892
1982
  }) : null;
1893
1983
  const wrapFarmDocsResponseWithLayouts = async (request, response) => {
1894
- if (request.method === "HEAD" || response.headers.has("x-farm-docs-adapter") || !_optionalChain([response, 'access', _124 => _124.headers, 'access', _125 => _125.get, 'call', _126 => _126("content-type"), 'optionalAccess', _127 => _127.toLowerCase, 'call', _128 => _128(), 'access', _129 => _129.includes, 'call', _130 => _130("text/html")])) {
1984
+ if (request.method === "HEAD" || response.headers.has("x-farm-docs-adapter") || !_optionalChain([response, 'access', _135 => _135.headers, 'access', _136 => _136.get, 'call', _137 => _137("content-type"), 'optionalAccess', _138 => _138.toLowerCase, 'call', _139 => _139(), 'access', _140 => _140.includes, 'call', _141 => _141("text/html")])) {
1895
1985
  return response;
1896
1986
  }
1897
1987
  const pathname = new URL(request.url).pathname;
1898
1988
  const matchedRoute = routeManager.matchRoute(pathname);
1899
1989
  const layoutEntries = matchedRoute.layouts.map((layout) => ({
1900
1990
  ...layout,
1901
- metadata: _chunkUYSTTPYJcjs.getClientModuleMetadata.call(void 0, layout.modulePath, farmConfig.root)
1991
+ metadata: _chunkGGNJAGGEcjs.getClientModuleMetadata.call(void 0, layout.modulePath, farmConfig.root)
1902
1992
  }));
1903
1993
  if (!layoutEntries.some((layout) => layout.metadata.shouldHydrate)) {
1904
1994
  return response;
@@ -1912,7 +2002,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1912
2002
  headers: response.headers
1913
2003
  });
1914
2004
  }
1915
- const docsRenderer = _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, (_nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _131 => _131.getConfig, 'call', _132 => _132()]), () => ( options))).renderer);
2005
+ const docsRenderer = _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, (_nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _142 => _142.getConfig, 'call', _143 => _143()]), () => ( options))).renderer);
1916
2006
  const [rendererRuntime, layoutModules] = await Promise.all([
1917
2007
  _chunkRD623KW4cjs.isReactRenderer.call(void 0, docsRenderer) ? import("./renderer/react/server.cjs") : _chunkJYNNIGQOcjs.loadFarmDevModule.call(void 0, server, docsRenderer.server),
1918
2008
  Promise.all(
@@ -1941,7 +2031,7 @@ function farmPlugin(options = {}, initialPluginManager) {
1941
2031
  ])
1942
2032
  );
1943
2033
  const inlineValue = (value) => JSON.stringify(value).replace(/</g, "\\u003c").replace(/>/g, "\\u003e");
1944
- const pageModulePath = _optionalChain([matchedRoute, 'access', _133 => _133.route, 'optionalAccess', _134 => _134.modulePath]) ? toUrlPath(matchedRoute.route.modulePath) : "";
2034
+ const pageModulePath = _optionalChain([matchedRoute, 'access', _144 => _144.route, 'optionalAccess', _145 => _145.modulePath]) ? toUrlPath(matchedRoute.route.modulePath) : "";
1945
2035
  const bootstrapScript = `<script>
1946
2036
  window.__FARM_PROPS__ = ${inlineValue({ params })};
1947
2037
  window.__FARM_ROUTE_SLOTS__ = [];
@@ -2037,8 +2127,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2037
2127
  }
2038
2128
  },
2039
2129
  (request) => {
2040
- const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _135 => _135.getConfig, 'call', _136 => _136()]), () => ( options));
2041
- const currentServerConfig = _chunkLIFUPCXWcjs.resolveFarmServerConfig.call(void 0, currentConfig.server);
2130
+ const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _146 => _146.getConfig, 'call', _147 => _147()]), () => ( options));
2131
+ const currentServerConfig = _chunkCFG4QERRcjs.resolveFarmServerConfig.call(void 0, currentConfig.server);
2042
2132
  return _chunkHNAISJFDcjs.resolveFarmRequestURL.call(void 0, request, {
2043
2133
  trustProxy: currentServerConfig.trustProxy
2044
2134
  });
@@ -2048,8 +2138,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2048
2138
  withAPIRequestTracing(async (req, res, next) => {
2049
2139
  const requestUrl = req.url || "/";
2050
2140
  const requestMethod = req.method || "GET";
2051
- const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _137 => _137.getConfig, 'call', _138 => _138()]), () => ( options));
2052
- const currentServerConfig = _chunkLIFUPCXWcjs.resolveFarmServerConfig.call(void 0, currentConfig.server);
2141
+ const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _148 => _148.getConfig, 'call', _149 => _149()]), () => ( options));
2142
+ const currentServerConfig = _chunkCFG4QERRcjs.resolveFarmServerConfig.call(void 0, currentConfig.server);
2053
2143
  const parsedRequestUrl = _chunkHNAISJFDcjs.resolveFarmRequestURL.call(void 0, req, {
2054
2144
  trustProxy: currentServerConfig.trustProxy
2055
2145
  });
@@ -2090,7 +2180,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2090
2180
  if (referrerUrl.origin === parsedRequestUrl.origin && !referrerUrl.pathname.startsWith(_chunkSTF6VDYQcjs.FARM_DEVTOOLS_PATH)) {
2091
2181
  launchUrl = referrerUrl;
2092
2182
  }
2093
- } catch (e13) {
2183
+ } catch (e15) {
2094
2184
  }
2095
2185
  }
2096
2186
  launchUrl.searchParams.set(_chunkSTF6VDYQcjs.FARM_DEVTOOLS_LAUNCH_PARAM, "1");
@@ -2116,7 +2206,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2116
2206
  openapi: options.openapi
2117
2207
  },
2118
2208
  workflows: discoveredWorkflows,
2119
- plugins: _optionalChain([pm, 'optionalAccess', _139 => _139.getSortedPlugins, 'call', _140 => _140()])
2209
+ plugins: _optionalChain([pm, 'optionalAccess', _150 => _150.getSortedPlugins, 'call', _151 => _151()])
2120
2210
  });
2121
2211
  res.statusCode = 200;
2122
2212
  res.setHeader(
@@ -2139,7 +2229,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2139
2229
  return;
2140
2230
  }
2141
2231
  const runAppMiddlewareForContentRoute = async () => {
2142
- if (!_optionalChain([middlewareManager, 'optionalAccess', _141 => _141.hasMiddleware, 'call', _142 => _142()])) return false;
2232
+ if (!_optionalChain([middlewareManager, 'optionalAccess', _152 => _152.hasMiddleware, 'call', _153 => _153()])) return false;
2143
2233
  const middlewareRequest = createRequestFromNodeRequest(req, new URL(fullUrl));
2144
2234
  return runFarmMiddlewareWithNavigation(
2145
2235
  farmApp.getServerRenderer(),
@@ -2155,16 +2245,16 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2155
2245
  label
2156
2246
  } = {}) => {
2157
2247
  const discard = async () => {
2158
- await _optionalChain([computed, 'optionalAccess', _143 => _143.body, 'optionalAccess', _144 => _144.cancel, 'call', _145 => _145(), 'access', _146 => _146.catch, 'call', _147 => _147(() => {
2248
+ await _optionalChain([computed, 'optionalAccess', _154 => _154.body, 'optionalAccess', _155 => _155.cancel, 'call', _156 => _156(), 'access', _157 => _157.catch, 'call', _158 => _158(() => {
2159
2249
  })]);
2160
2250
  };
2161
2251
  let runtimeSession2;
2162
- if (_optionalChain([pm, 'optionalAccess', _148 => _148.hasRuntimeRequestHooks, 'call', _149 => _149()])) {
2252
+ if (_optionalChain([pm, 'optionalAccess', _159 => _159.hasRuntimeRequestHooks, 'call', _160 => _160()])) {
2163
2253
  try {
2164
2254
  const routePathname = _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath);
2165
- const route = _chunkDPJ66FSIcjs.setFarmRouteLabel.call(void 0,
2255
+ const route = _chunkXX32BOMMcjs.setFarmRouteLabel.call(void 0,
2166
2256
  { pathname: requestPathname },
2167
- label !== void 0 ? label : devBuiltInRoutePaths.has(routePathname) ? routePathname : _chunkDPJ66FSIcjs.resolveFarmMCPRouteLabel.call(void 0, routePathname, apiServerBasePath)
2257
+ label !== void 0 ? label : devBuiltInRoutePaths.has(routePathname) ? routePathname : _chunkXX32BOMMcjs.resolveFarmMCPRouteLabel.call(void 0, routePathname, apiServerBasePath)
2168
2258
  );
2169
2259
  runtimeSession2 = await pm.beginRuntimeRequest(
2170
2260
  createRequestFromNodeRequest(req, new URL(fullUrl)),
@@ -2196,7 +2286,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2196
2286
  let response;
2197
2287
  try {
2198
2288
  response = await respond(
2199
- _nullishCoalesce(_optionalChain([runtimeSession2, 'optionalAccess', _150 => _150.request]), () => ( createRequestFromNodeRequest(req, new URL(fullUrl))))
2289
+ _nullishCoalesce(_optionalChain([runtimeSession2, 'optionalAccess', _161 => _161.request]), () => ( createRequestFromNodeRequest(req, new URL(fullUrl))))
2200
2290
  );
2201
2291
  } catch (error) {
2202
2292
  if (runtimeSession2) await pm.failRuntimeRequest(runtimeSession2, error);
@@ -2209,7 +2299,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2209
2299
  );
2210
2300
  };
2211
2301
  const openAPIRequestPathname = openAPIManager ? _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath) : requestPathname;
2212
- if (openAPIManager && _optionalChain([options, 'access', _151 => _151.openapi, 'optionalAccess', _152 => _152.specRoute]) && openAPIRequestPathname === options.openapi.specRoute) {
2302
+ if (openAPIManager && _optionalChain([options, 'access', _162 => _162.openapi, 'optionalAccess', _163 => _163.specRoute]) && openAPIRequestPathname === options.openapi.specRoute) {
2213
2303
  const specManager = openAPIManager;
2214
2304
  await serveBuiltInRoute(async () => {
2215
2305
  if (requestMethod !== "GET" && requestMethod !== "HEAD") {
@@ -2229,7 +2319,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2229
2319
  });
2230
2320
  return;
2231
2321
  }
2232
- if (openAPIManager && openAPIRequestPathname === _optionalChain([options, 'access', _153 => _153.openapi, 'optionalAccess', _154 => _154.route])) {
2322
+ if (openAPIManager && openAPIRequestPathname === _optionalChain([options, 'access', _164 => _164.openapi, 'optionalAccess', _165 => _165.route])) {
2233
2323
  const docsManager = openAPIManager;
2234
2324
  await serveBuiltInRoute(
2235
2325
  async () => {
@@ -2240,29 +2330,29 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2240
2330
  );
2241
2331
  return;
2242
2332
  }
2243
- if (_optionalChain([options, 'access', _155 => _155.agent, 'optionalAccess', _156 => _156.manifest]) !== false && _chunkDPJ66FSIcjs.isFarmAppManifestPath.call(void 0, _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath))) {
2333
+ if (_optionalChain([options, 'access', _166 => _166.agent, 'optionalAccess', _167 => _167.manifest]) !== false && _chunkXX32BOMMcjs.isFarmAppManifestPath.call(void 0, _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath))) {
2244
2334
  await serveBuiltInRoute(async () => {
2245
- _nullishCoalesce(farmAppPackages, () => ( (farmAppPackages = _chunkUYSTTPYJcjs.resolveFarmAppPackages.call(void 0, _nullishCoalesce(farmConfig.root, () => ( process.cwd()))))));
2246
- const manifest = await _chunkDPJ66FSIcjs.createFarmAppManifestResponse.call(void 0,
2335
+ _nullishCoalesce(farmAppPackages, () => ( (farmAppPackages = _chunkGGNJAGGEcjs.resolveFarmAppPackages.call(void 0, _nullishCoalesce(farmConfig.root, () => ( process.cwd()))))));
2336
+ const manifest = await _chunkXX32BOMMcjs.createFarmAppManifestResponse.call(void 0,
2247
2337
  new Request(parsedRequestUrl, {
2248
2338
  method: requestMethod,
2249
2339
  headers: { "if-none-match": String(_nullishCoalesce(req.headers["if-none-match"], () => ( ""))) }
2250
2340
  }),
2251
2341
  {
2252
- ..._chunkDPJ66FSIcjs.resolveFarmAppManifestInput.call(void 0, farmConfig, {
2342
+ ..._chunkXX32BOMMcjs.resolveFarmAppManifestInput.call(void 0, farmConfig, {
2253
2343
  build: "development",
2254
2344
  packages: farmAppPackages,
2255
2345
  // Read again on each request; unchanged files come from a cache.
2256
- webmcpTools: _optionalChain([farmConfig, 'access', _157 => _157.plugins, 'optionalAccess', _158 => _158.some, 'call', _159 => _159(({ name }) => name === "farm:webmcp")]) ? _chunkUYSTTPYJcjs.collectFarmWebMCPTools.call(void 0, _nullishCoalesce(farmConfig.root, () => ( process.cwd())), farmConfig.srcDir) : []
2346
+ webmcpTools: _optionalChain([farmConfig, 'access', _168 => _168.plugins, 'optionalAccess', _169 => _169.some, 'call', _170 => _170(({ name }) => name === "farm:webmcp")]) ? _chunkGGNJAGGEcjs.collectFarmWebMCPTools.call(void 0, _nullishCoalesce(farmConfig.root, () => ( process.cwd())), farmConfig.srcDir) : []
2257
2347
  }),
2258
2348
  defaultMCP: () => farmApp.getServerRenderer().getDefaultMCPServer(),
2259
2349
  // A guard written for an MCP server's path keeps its tools out of the public view.
2260
- guardCoversPath: (path6) => _chunkO27PLNQZcjs.farmPathGuardCoversEndpoint.call(void 0,
2350
+ guardCoversPath: (path7) => _chunkO27PLNQZcjs.farmPathGuardCoversEndpoint.call(void 0,
2261
2351
  {
2262
2352
  config: farmConfig,
2263
2353
  middlewareRoutes: middlewareManager.getMiddlewares().filter((entry) => entry.source !== "config")
2264
2354
  },
2265
- path6,
2355
+ path7,
2266
2356
  apiServerBasePath
2267
2357
  )
2268
2358
  }
@@ -2271,11 +2361,11 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2271
2361
  });
2272
2362
  return;
2273
2363
  }
2274
- if (_optionalChain([options, 'access', _160 => _160.agent, 'optionalAccess', _161 => _161.apiCatalog]) && _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath) === _chunkDPJ66FSIcjs.FARM_API_CATALOG_PATH) {
2364
+ if (_optionalChain([options, 'access', _171 => _171.agent, 'optionalAccess', _172 => _172.apiCatalog]) && _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath) === _chunkXX32BOMMcjs.FARM_API_CATALOG_PATH) {
2275
2365
  await serveBuiltInRoute(
2276
- () => _chunkDPJ66FSIcjs.createFarmApiCatalogResponse.call(void 0,
2366
+ () => _chunkXX32BOMMcjs.createFarmApiCatalogResponse.call(void 0,
2277
2367
  requestMethod,
2278
- _chunkDPJ66FSIcjs.resolveFarmApiCatalogInput.call(void 0, { ...options, api: farmConfig.api }),
2368
+ _chunkXX32BOMMcjs.resolveFarmApiCatalogInput.call(void 0, { ...options, api: farmConfig.api }),
2279
2369
  new Request(parsedRequestUrl, {
2280
2370
  headers: { "user-agent": String(_nullishCoalesce(req.headers["user-agent"], () => ( ""))) }
2281
2371
  })
@@ -2283,8 +2373,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2283
2373
  );
2284
2374
  return;
2285
2375
  }
2286
- if (_optionalChain([options, 'access', _162 => _162.agent, 'optionalAccess', _163 => _163.aiCatalog]) !== false) {
2287
- const aiCatalog = _chunkDPJ66FSIcjs.createFarmAiCatalogResponse.call(void 0,
2376
+ if (_optionalChain([options, 'access', _173 => _173.agent, 'optionalAccess', _174 => _174.aiCatalog]) !== false) {
2377
+ const aiCatalog = _chunkXX32BOMMcjs.createFarmAiCatalogResponse.call(void 0,
2288
2378
  new Request(parsedRequestUrl, {
2289
2379
  method: requestMethod,
2290
2380
  headers: {
@@ -2320,7 +2410,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2320
2410
  method: requestMethod,
2321
2411
  headers: docsHeaders
2322
2412
  });
2323
- const docsBodyInit = requestMethod === "GET" || requestMethod === "HEAD" ? {} : { body: _chunkLIFUPCXWcjs.createFarmNodeRequestBodyStream.call(void 0, req), duplex: "half" };
2413
+ const docsBodyInit = requestMethod === "GET" || requestMethod === "HEAD" ? {} : { body: _chunkCFG4QERRcjs.createFarmNodeRequestBodyStream.call(void 0, req), duplex: "half" };
2324
2414
  const docsResponse = await farmDocsHandler(new Request(docsRequest, docsBodyInit));
2325
2415
  if (docsResponse) {
2326
2416
  await serveBuiltInRoute(
@@ -2328,11 +2418,11 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2328
2418
  {
2329
2419
  kind: "docs",
2330
2420
  computed: docsResponse,
2331
- label: _chunkDPJ66FSIcjs.resolveFarmDocsEngineRouteLabel.call(void 0,
2421
+ label: _chunkXX32BOMMcjs.resolveFarmDocsEngineRouteLabel.call(void 0,
2332
2422
  _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath),
2333
2423
  {
2334
- path: _optionalChain([farmConfig, 'access', _164 => _164.docs, 'optionalAccess', _165 => _165.entry]) || "/docs",
2335
- roots: _optionalChain([farmConfig, 'access', _166 => _166.docs, 'optionalAccess', _167 => _167.roots, 'optionalAccess', _168 => _168.map, 'call', _169 => _169((root) => root.entry)])
2424
+ path: _optionalChain([farmConfig, 'access', _175 => _175.docs, 'optionalAccess', _176 => _176.entry]) || "/docs",
2425
+ roots: _optionalChain([farmConfig, 'access', _177 => _177.docs, 'optionalAccess', _178 => _178.roots, 'optionalAccess', _179 => _179.map, 'call', _180 => _180((root) => root.entry)])
2336
2426
  }
2337
2427
  )
2338
2428
  }
@@ -2340,26 +2430,26 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2340
2430
  return;
2341
2431
  }
2342
2432
  }
2343
- if (options.mobileClient && !viteModuleRequest && (requestMethod === "GET" || requestMethod === "HEAD") && _optionalChain([req, 'access', _170 => _170.headers, 'access', _171 => _171.accept, 'optionalAccess', _172 => _172.includes, 'call', _173 => _173(_chunk3HLQTOVUcjs.FARM_NATIVE_TREE_CONTENT_TYPE)])) {
2344
- const { createFarmNativeTreeResponse } = await import("./native-tree-6G5O53O3.cjs");
2433
+ if (options.mobileClient && !viteModuleRequest && (requestMethod === "GET" || requestMethod === "HEAD") && _optionalChain([req, 'access', _181 => _181.headers, 'access', _182 => _182.accept, 'optionalAccess', _183 => _183.includes, 'call', _184 => _184(_chunk3HLQTOVUcjs.FARM_NATIVE_TREE_CONTENT_TYPE)])) {
2434
+ const { createFarmNativeTreeResponse } = await import("./native-tree-Z2WYUJEV.cjs");
2345
2435
  const treeResponse = await createFarmNativeTreeResponse({
2346
2436
  request: new Request(fullUrl, { method: requestMethod, headers: docsHeaders }),
2347
2437
  // As for the Markdown mirror: this server's own listener, redirects not followed.
2348
2438
  renderPage: (request) => _chunkBNH53KOTcjs.createFarmDevServerDispatch.call(void 0, server)(
2349
2439
  new Request(request, {
2350
- signal: res.destroyed ? AbortSignal.abort() : _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2440
+ signal: res.destroyed ? AbortSignal.abort() : _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2351
2441
  })
2352
2442
  )
2353
2443
  });
2354
2444
  await serveBuiltInRoute(() => treeResponse, {
2355
2445
  computed: treeResponse,
2356
- label: _nullishCoalesce(_optionalChain([farmApp, 'access', _174 => _174.getRouteManager, 'call', _175 => _175(), 'access', _176 => _176.matchRoute, 'call', _177 => _177(_chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath)), 'access', _178 => _178.route, 'optionalAccess', _179 => _179.pattern]), () => ( null))
2446
+ label: _nullishCoalesce(_optionalChain([farmApp, 'access', _185 => _185.getRouteManager, 'call', _186 => _186(), 'access', _187 => _187.matchRoute, 'call', _188 => _188(_chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath)), 'access', _189 => _189.route, 'optionalAccess', _190 => _190.pattern]), () => ( null))
2357
2447
  });
2358
2448
  return;
2359
2449
  }
2360
- const markdownRouteLabel = () => _chunkDPJ66FSIcjs.resolveFarmMarkdownRouteLabel.call(void 0,
2450
+ const markdownRouteLabel = () => _chunkXX32BOMMcjs.resolveFarmMarkdownRouteLabel.call(void 0,
2361
2451
  _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, requestPathname, farmConfig.basePath),
2362
- (page) => _optionalChain([farmApp, 'access', _180 => _180.getRouteManager, 'call', _181 => _181(), 'access', _182 => _182.matchRoute, 'call', _183 => _183(page), 'access', _184 => _184.route, 'optionalAccess', _185 => _185.pattern])
2452
+ (page) => _optionalChain([farmApp, 'access', _191 => _191.getRouteManager, 'call', _192 => _192(), 'access', _193 => _193.matchRoute, 'call', _194 => _194(page), 'access', _195 => _195.route, 'optionalAccess', _196 => _196.pattern])
2363
2453
  );
2364
2454
  const markdownSourceResponse = viteModuleRequest ? null : await _chunkPRFNLQSPcjs.createFarmMarkdownSourceResponse.call(void 0, {
2365
2455
  request: new Request(fullUrl, {
@@ -2369,7 +2459,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2369
2459
  config: farmApp.getConfig().mdx,
2370
2460
  resolveSource: async (pathname2) => {
2371
2461
  const match = farmApp.getRouteManager().matchRoute(pathname2);
2372
- const sourcePath = _optionalChain([match, 'access', _186 => _186.route, 'optionalAccess', _187 => _187.markdownSourcePath]) || (match.route && _chunkPRFNLQSPcjs.isFarmMarkdownPageFile.call(void 0, match.route.modulePath) ? match.route.modulePath : null);
2462
+ const sourcePath = _optionalChain([match, 'access', _197 => _197.route, 'optionalAccess', _198 => _198.markdownSourcePath]) || (match.route && _chunkPRFNLQSPcjs.isFarmMarkdownPageFile.call(void 0, match.route.modulePath) ? match.route.modulePath : null);
2373
2463
  if (!sourcePath) {
2374
2464
  return null;
2375
2465
  }
@@ -2383,7 +2473,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2383
2473
  // this server's own listener, never the host the caller's Host names.
2384
2474
  renderPage: async (request) => _chunkBNH53KOTcjs.createFarmDevServerDispatch.call(void 0, server)(
2385
2475
  new Request(request, {
2386
- signal: res.destroyed ? AbortSignal.abort() : _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2476
+ signal: res.destroyed ? AbortSignal.abort() : _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2387
2477
  })
2388
2478
  )
2389
2479
  });
@@ -2412,7 +2502,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2412
2502
  headers,
2413
2503
  // Only accepted mirrors need disconnect listeners. An earlier
2414
2504
  // close (for example while the docs handler ran) must also abort.
2415
- signal: res.destroyed ? AbortSignal.abort() : _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2505
+ signal: res.destroyed ? AbortSignal.abort() : _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2416
2506
  })
2417
2507
  );
2418
2508
  },
@@ -2469,13 +2559,13 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2469
2559
  let workflowBody;
2470
2560
  try {
2471
2561
  if (requestMethod !== "GET" && requestMethod !== "HEAD") {
2472
- workflowBody = await _chunkLIFUPCXWcjs.readNodeRequestBody.call(void 0,
2562
+ workflowBody = await _chunkCFG4QERRcjs.readNodeRequestBody.call(void 0,
2473
2563
  req,
2474
2564
  currentServerConfig.bodySizeLimit
2475
2565
  );
2476
2566
  }
2477
2567
  } catch (error) {
2478
- const response = _chunkLIFUPCXWcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2568
+ const response = _chunkCFG4QERRcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2479
2569
  if (!response) throw error;
2480
2570
  await _chunkYIHRZBD7cjs.sendWebResponse.call(void 0, res, response);
2481
2571
  return;
@@ -2485,7 +2575,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2485
2575
  method: requestMethod,
2486
2576
  headers: docsHeaders,
2487
2577
  body: toRequestBody(workflowBody),
2488
- signal: _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2578
+ signal: _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2489
2579
  })
2490
2580
  );
2491
2581
  if (workflowResponse) {
@@ -2495,7 +2585,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2495
2585
  }
2496
2586
  const configuredIntegrations = currentConfig.integrations;
2497
2587
  const tryConfiguredIntegrationRoute = async () => {
2498
- const matchedRoute = _chunkZP32GNJQcjs.matchIntegrationRoute.call(void 0, configuredIntegrations, {
2588
+ const matchedRoute = _chunkI32V5CZLcjs.matchIntegrationRoute.call(void 0, configuredIntegrations, {
2499
2589
  pathname: requestPathname,
2500
2590
  method: requestMethod
2501
2591
  });
@@ -2508,8 +2598,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2508
2598
  await pm.runHookParallelFiltered(
2509
2599
  "beforeRequest",
2510
2600
  (plugin) => {
2511
- const owner = _chunkZP32GNJQcjs.getFarmIntegrationPluginOwner.call(void 0, plugin);
2512
- return plugin.name !== _chunkUYTAP4FQcjs.FARM_CONFIG_REWRITES_PLUGIN_NAME && (_optionalChain([owner, 'optionalAccess', _188 => _188.source]) !== "lifecycle" || owner.key !== matchedRoute.key);
2601
+ const owner = _chunkI32V5CZLcjs.getFarmIntegrationPluginOwner.call(void 0, plugin);
2602
+ return plugin.name !== _chunkUYTAP4FQcjs.FARM_CONFIG_REWRITES_PLUGIN_NAME && (_optionalChain([owner, 'optionalAccess', _199 => _199.source]) !== "lifecycle" || owner.key !== matchedRoute.key);
2513
2603
  },
2514
2604
  req,
2515
2605
  res
@@ -2528,16 +2618,16 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2528
2618
  }
2529
2619
  let body;
2530
2620
  if (req.method !== "GET" && req.method !== "HEAD") {
2531
- body = await _chunkLIFUPCXWcjs.readNodeRequestBody.call(void 0, req, currentServerConfig.bodySizeLimit);
2621
+ body = await _chunkCFG4QERRcjs.readNodeRequestBody.call(void 0, req, currentServerConfig.bodySizeLimit);
2532
2622
  }
2533
2623
  const integrationRequest = new Request(fullUrl, {
2534
2624
  method: req.method,
2535
2625
  headers,
2536
2626
  body: toRequestBody(body),
2537
- signal: _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2627
+ signal: _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2538
2628
  });
2539
2629
  const dispatchIntegration = async (request) => {
2540
- const result = await _chunkZP32GNJQcjs.dispatchIntegrationRequest.call(void 0,
2630
+ const result = await _chunkI32V5CZLcjs.dispatchIntegrationRequest.call(void 0,
2541
2631
  {
2542
2632
  integration: matchedRoute.integration,
2543
2633
  config: currentConfig,
@@ -2545,7 +2635,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2545
2635
  isProd: false
2546
2636
  },
2547
2637
  request,
2548
- { clientAddress: _optionalChain([req, 'access', _189 => _189.socket, 'optionalAccess', _190 => _190.remoteAddress]) }
2638
+ { clientAddress: _optionalChain([req, 'access', _200 => _200.socket, 'optionalAccess', _201 => _201.remoteAddress]) }
2549
2639
  );
2550
2640
  if (!result) {
2551
2641
  throw new Error(`Matched integration route did not return a response`);
@@ -2567,7 +2657,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2567
2657
  await _chunkYIHRZBD7cjs.sendWebResponse.call(void 0, res, response);
2568
2658
  return true;
2569
2659
  } catch (error) {
2570
- const bodyErrorResponse = _chunkLIFUPCXWcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2660
+ const bodyErrorResponse = _chunkCFG4QERRcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2571
2661
  if (bodyErrorResponse) {
2572
2662
  await _chunkYIHRZBD7cjs.sendWebResponse.call(void 0, res, bodyErrorResponse);
2573
2663
  return true;
@@ -2601,7 +2691,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2601
2691
  }
2602
2692
  const matchedApiRoute = apiRouteManager.matchRoute(requestPathname);
2603
2693
  const hasMatchedApiRoute = Boolean(matchedApiRoute);
2604
- if (hasMatchedApiRoute || _chunkCBKRS3M4cjs.isFarmAPIPathname.call(void 0, requestPathname, apiServerBasePath)) {
2694
+ if (hasMatchedApiRoute || _chunkZ7P2BTZ3cjs.isFarmAPIPathname.call(void 0, requestPathname, apiServerBasePath)) {
2605
2695
  const startTime2 = Date.now();
2606
2696
  const method2 = req.method || "GET";
2607
2697
  const urlPath2 = req.url || "/";
@@ -2609,7 +2699,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2609
2699
  trustProxy: currentServerConfig.trustProxy
2610
2700
  }).pathname;
2611
2701
  const servesLocalApiRoute = hasMatchedApiRoute || Boolean(
2612
- farmDocsAPIHandler && _optionalChain([farmDocsDevRuntime, 'optionalAccess', _191 => _191.isFarmDocsAPIRequest, 'call', _192 => _192(requestPathname)])
2702
+ farmDocsAPIHandler && _optionalChain([farmDocsDevRuntime, 'optionalAccess', _202 => _202.isFarmDocsAPIRequest, 'call', _203 => _203(requestPathname)])
2613
2703
  );
2614
2704
  try {
2615
2705
  if (pm) {
@@ -2653,7 +2743,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2653
2743
  const routedApiRoute = rewritten ? apiRouteManager.matchRoute(routedPathname) : matchedApiRoute || apiRouteManager.matchRoute(pathname2);
2654
2744
  const hasExplicitAPIRoute = Boolean(routedApiRoute);
2655
2745
  if (apiHandler && hasExplicitAPIRoute) {
2656
- const apiRoutePattern = _optionalChain([routedApiRoute, 'optionalAccess', _193 => _193.route, 'access', _194 => _194.path]) || urlPath2;
2746
+ const apiRoutePattern = _optionalChain([routedApiRoute, 'optionalAccess', _204 => _204.route, 'access', _205 => _205.path]) || urlPath2;
2657
2747
  _chunkEVIWKPJVcjs.emitFarmEvent.call(void 0, {
2658
2748
  type: "route.matched",
2659
2749
  pathname: pathname2,
@@ -2675,13 +2765,13 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2675
2765
  }
2676
2766
  let body;
2677
2767
  if (req.method !== "GET" && req.method !== "HEAD") {
2678
- body = await _chunkLIFUPCXWcjs.readNodeRequestBody.call(void 0, req, currentServerConfig.bodySizeLimit);
2768
+ body = await _chunkCFG4QERRcjs.readNodeRequestBody.call(void 0, req, currentServerConfig.bodySizeLimit);
2679
2769
  }
2680
2770
  const request = new Request(url, {
2681
2771
  method: req.method,
2682
2772
  headers,
2683
2773
  body: toRequestBody(body),
2684
- signal: _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2774
+ signal: _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2685
2775
  });
2686
2776
  const apiLifecyclePayload = {
2687
2777
  pathname: new URL(url).pathname,
@@ -2726,7 +2816,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2726
2816
  durationMs: duration2,
2727
2817
  error
2728
2818
  });
2729
- const bodyErrorResponse = _chunkLIFUPCXWcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2819
+ const bodyErrorResponse = _chunkCFG4QERRcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2730
2820
  if (bodyErrorResponse) {
2731
2821
  logResponse(method2, urlPath2, bodyErrorResponse.status, duration2, "API");
2732
2822
  await _chunkYIHRZBD7cjs.sendWebResponse.call(void 0, res, bodyErrorResponse);
@@ -2743,7 +2833,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2743
2833
  return;
2744
2834
  }
2745
2835
  }
2746
- if (farmDocsAPIHandler && _optionalChain([farmDocsDevRuntime, 'optionalAccess', _195 => _195.isFarmDocsAPIRequest, 'call', _196 => _196(pathname2)])) {
2836
+ if (farmDocsAPIHandler && _optionalChain([farmDocsDevRuntime, 'optionalAccess', _206 => _206.isFarmDocsAPIRequest, 'call', _207 => _207(pathname2)])) {
2747
2837
  try {
2748
2838
  const url = `http://${req.headers.host || "localhost:3000"}${req.url}`;
2749
2839
  const headers = new Headers();
@@ -2754,13 +2844,13 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2754
2844
  }
2755
2845
  let body;
2756
2846
  if (req.method !== "GET" && req.method !== "HEAD") {
2757
- body = await _chunkLIFUPCXWcjs.readNodeRequestBody.call(void 0, req, currentServerConfig.bodySizeLimit);
2847
+ body = await _chunkCFG4QERRcjs.readNodeRequestBody.call(void 0, req, currentServerConfig.bodySizeLimit);
2758
2848
  }
2759
2849
  const request = new Request(url, {
2760
2850
  method: req.method,
2761
2851
  headers,
2762
2852
  body: toRequestBody(body),
2763
- signal: _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2853
+ signal: _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2764
2854
  });
2765
2855
  const apiLifecyclePayload = {
2766
2856
  pathname: pathname2,
@@ -2781,11 +2871,11 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2781
2871
  };
2782
2872
  const docsResponse = pm ? await pm.runRuntimeRequest(request, invokeDocsAPIHandler, {
2783
2873
  kind: "docs",
2784
- route: _chunkDPJ66FSIcjs.setFarmRouteLabel.call(void 0,
2874
+ route: _chunkXX32BOMMcjs.setFarmRouteLabel.call(void 0,
2785
2875
  { pathname: pathname2, pattern: apiLifecyclePayload.routePath },
2786
- _chunkDPJ66FSIcjs.resolveFarmDocsRouteLabel.call(void 0, pathname2, {
2787
- path: _optionalChain([farmConfig, 'access', _197 => _197.docs, 'optionalAccess', _198 => _198.entry]) || "/docs",
2788
- roots: _optionalChain([farmConfig, 'access', _199 => _199.docs, 'optionalAccess', _200 => _200.roots, 'optionalAccess', _201 => _201.map, 'call', _202 => _202((root) => root.entry)])
2876
+ _chunkXX32BOMMcjs.resolveFarmDocsRouteLabel.call(void 0, pathname2, {
2877
+ path: _optionalChain([farmConfig, 'access', _208 => _208.docs, 'optionalAccess', _209 => _209.entry]) || "/docs",
2878
+ roots: _optionalChain([farmConfig, 'access', _210 => _210.docs, 'optionalAccess', _211 => _211.roots, 'optionalAccess', _212 => _212.map, 'call', _213 => _213((root) => root.entry)])
2789
2879
  })
2790
2880
  )
2791
2881
  }) : await invokeDocsAPIHandler(request);
@@ -2796,7 +2886,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2796
2886
  return;
2797
2887
  }
2798
2888
  } catch (error) {
2799
- const bodyErrorResponse = _chunkLIFUPCXWcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2889
+ const bodyErrorResponse = _chunkCFG4QERRcjs.createFarmRequestBodyErrorResponse.call(void 0, error);
2800
2890
  if (bodyErrorResponse) {
2801
2891
  await _chunkYIHRZBD7cjs.sendWebResponse.call(void 0, res, bodyErrorResponse);
2802
2892
  return;
@@ -2819,25 +2909,25 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2819
2909
  res.end(JSON.stringify({ error: "API route not found", pathname: pathname2 }));
2820
2910
  return;
2821
2911
  }
2822
- if (_optionalChain([req, 'access', _203 => _203.url, 'optionalAccess', _204 => _204.startsWith, 'call', _205 => _205("/@")]) || _optionalChain([req, 'access', _206 => _206.url, 'optionalAccess', _207 => _207.startsWith, 'call', _208 => _208("/node_modules")])) {
2912
+ if (_optionalChain([req, 'access', _214 => _214.url, 'optionalAccess', _215 => _215.startsWith, 'call', _216 => _216("/@")]) || _optionalChain([req, 'access', _217 => _217.url, 'optionalAccess', _218 => _218.startsWith, 'call', _219 => _219("/node_modules")])) {
2823
2913
  return next();
2824
2914
  }
2825
2915
  if (shouldBypassFarmRouterForDottedPath(
2826
2916
  requestPathname,
2827
- _optionalChain([farmApp, 'optionalAccess', _209 => _209.getRouteManager, 'call', _210 => _210()]),
2917
+ _optionalChain([farmApp, 'optionalAccess', _220 => _220.getRouteManager, 'call', _221 => _221()]),
2828
2918
  [server.config.publicDir, server.config.root],
2829
2919
  farmAgentGeneratedPaths(farmConfig)
2830
2920
  )) {
2831
2921
  return next();
2832
2922
  }
2833
- if (_optionalChain([req, 'access', _211 => _211.url, 'optionalAccess', _212 => _212.startsWith, 'call', _213 => _213("/__farm/page-data")])) {
2923
+ if (_optionalChain([req, 'access', _222 => _222.url, 'optionalAccess', _223 => _223.startsWith, 'call', _224 => _224("/__farm/page-data")])) {
2834
2924
  const urlObj = parsedRequestUrl;
2835
2925
  const targetPath = urlObj.searchParams.get("path") || "/";
2836
2926
  try {
2837
2927
  const request = createRequestFromNodeRequest(
2838
2928
  req,
2839
2929
  urlObj,
2840
- _chunkLIFUPCXWcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2930
+ _chunkCFG4QERRcjs.createFarmNodeRequestAbortSignal.call(void 0, req, res)
2841
2931
  );
2842
2932
  const deploymentMismatch = _chunkE552H232cjs.getFarmDeploymentMismatch.call(void 0,
2843
2933
  request,
@@ -2858,7 +2948,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2858
2948
  });
2859
2949
  let middlewareMap = /* @__PURE__ */ new Map();
2860
2950
  let middlewareContext = /* @__PURE__ */ new Map();
2861
- if (_optionalChain([middlewareManager, 'optionalAccess', _214 => _214.hasMiddleware, 'call', _215 => _215()])) {
2951
+ if (_optionalChain([middlewareManager, 'optionalAccess', _225 => _225.hasMiddleware, 'call', _226 => _226()])) {
2862
2952
  const targetNodeRequest = createPageDataMiddlewareRequest(req, targetRequestUrl);
2863
2953
  const handled = await runFarmMiddlewareWithNavigation(
2864
2954
  farmApp.getServerRenderer(),
@@ -2886,10 +2976,10 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2886
2976
  if (pm) {
2887
2977
  await pm.runHookParallel("afterRouteMatch", {
2888
2978
  pathname: targetPath,
2889
- matched: !!_optionalChain([match, 'optionalAccess', _216 => _216.route]),
2890
- routePattern: _optionalChain([match, 'optionalAccess', _217 => _217.route, 'optionalAccess', _218 => _218.pattern]) || null,
2891
- params: _optionalChain([match, 'optionalAccess', _219 => _219.params]) || {},
2892
- layoutPatterns: (_optionalChain([match, 'optionalAccess', _220 => _220.layouts]) || []).map((l) => l.pattern)
2979
+ matched: !!_optionalChain([match, 'optionalAccess', _227 => _227.route]),
2980
+ routePattern: _optionalChain([match, 'optionalAccess', _228 => _228.route, 'optionalAccess', _229 => _229.pattern]) || null,
2981
+ params: _optionalChain([match, 'optionalAccess', _230 => _230.params]) || {},
2982
+ layoutPatterns: (_optionalChain([match, 'optionalAccess', _231 => _231.layouts]) || []).map((l) => l.pattern)
2893
2983
  });
2894
2984
  }
2895
2985
  if (!match) {
@@ -2912,7 +3002,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2912
3002
  );
2913
3003
  const loadingModule = loadingBoundary ? await routeManager3.loadRouteModule(loadingBoundary.modulePath) : null;
2914
3004
  const navigationManifest = routeManager3.generateClientManifest(server.config.root);
2915
- const moduleMetadata = _nullishCoalesce(navigationManifest.routes.find((entry) => entry.pattern === route.pattern), () => ( _chunkUYSTTPYJcjs.getClientModuleMetadata.call(void 0, route.modulePath, server.config.root)));
3005
+ const moduleMetadata = _nullishCoalesce(navigationManifest.routes.find((entry) => entry.pattern === route.pattern), () => ( _chunkGGNJAGGEcjs.getClientModuleMetadata.call(void 0, route.modulePath, server.config.root)));
2916
3006
  const isClientComponent = moduleMetadata.isClientComponent;
2917
3007
  const shouldHydrate = moduleMetadata.shouldHydrate;
2918
3008
  let mergedMetadata = {};
@@ -2920,7 +3010,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2920
3010
  layouts.map((layout) => routeManager3.loadLayoutModule(layout.modulePath))
2921
3011
  );
2922
3012
  const layoutHydrationMetadata = layouts.map(
2923
- (layout) => _nullishCoalesce(navigationManifest.layouts.find((entry) => entry.pattern === layout.pattern), () => ( _chunkUYSTTPYJcjs.getClientModuleMetadata.call(void 0, layout.modulePath, server.config.root)))
3013
+ (layout) => _nullishCoalesce(navigationManifest.layouts.find((entry) => entry.pattern === layout.pattern), () => ( _chunkGGNJAGGEcjs.getClientModuleMetadata.call(void 0, layout.modulePath, server.config.root)))
2924
3014
  );
2925
3015
  const shouldHydrateLayout = layoutHydrationMetadata.some(
2926
3016
  (metadata) => metadata.shouldHydrate
@@ -2932,17 +3022,17 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2932
3022
  )
2933
3023
  ];
2934
3024
  const hydrationIslandStrategy = _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0,
2935
- _optionalChain([(_nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _221 => _221.getConfig, 'call', _222 => _222()]), () => ( options))), 'access', _223 => _223.experimental, 'optionalAccess', _224 => _224.serverComponents])
2936
- ) === "islands" ? _chunkUYSTTPYJcjs.resolveFarmRouteRootStrategy.call(void 0,
3025
+ _optionalChain([(_nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _232 => _232.getConfig, 'call', _233 => _233()]), () => ( options))), 'access', _234 => _234.experimental, 'optionalAccess', _235 => _235.serverComponents])
3026
+ ) === "islands" ? _chunkGGNJAGGEcjs.resolveFarmRouteRootStrategy.call(void 0,
2937
3027
  route,
2938
3028
  { shouldHydrate, islandStrategy: _nullishCoalesce(moduleMetadata.islandStrategy, () => ( null)) },
2939
3029
  layouts.map((layout, index) => ({
2940
3030
  pattern: layout.pattern,
2941
3031
  modulePath: layout.modulePath,
2942
- shouldHydrate: _optionalChain([layoutHydrationMetadata, 'access', _225 => _225[index], 'optionalAccess', _226 => _226.shouldHydrate]) === true,
3032
+ shouldHydrate: _optionalChain([layoutHydrationMetadata, 'access', _236 => _236[index], 'optionalAccess', _237 => _237.shouldHydrate]) === true,
2943
3033
  // Manifest entries carry it; metadata read from source does not.
2944
- hasIsolatedClientBoundaries: _optionalChain([layoutHydrationMetadata, 'access', _227 => _227[index], 'optionalAccess', _228 => _228.hasIsolatedClientBoundaries]) === true,
2945
- islandStrategy: _nullishCoalesce(_optionalChain([layoutHydrationMetadata, 'access', _229 => _229[index], 'optionalAccess', _230 => _230.islandStrategy]), () => ( null))
3034
+ hasIsolatedClientBoundaries: _optionalChain([layoutHydrationMetadata, 'access', _238 => _238[index], 'optionalAccess', _239 => _239.hasIsolatedClientBoundaries]) === true,
3035
+ islandStrategy: _nullishCoalesce(_optionalChain([layoutHydrationMetadata, 'access', _240 => _240[index], 'optionalAccess', _241 => _241.islandStrategy]), () => ( null))
2946
3036
  })),
2947
3037
  server.config.root,
2948
3038
  true
@@ -2997,7 +3087,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2997
3087
  const slotModule = await routeManager3.loadRouteModule(slot.route.modulePath);
2998
3088
  const slotMetadata = _nullishCoalesce(navigationManifest.slots.find(
2999
3089
  (entry) => entry.name === slot.name && entry.ownerPattern === slot.ownerPattern && entry.pattern === slot.route.pattern
3000
- ), () => ( _chunkUYSTTPYJcjs.getClientModuleMetadata.call(void 0, slot.route.modulePath, server.config.root)));
3090
+ ), () => ( _chunkGGNJAGGEcjs.getClientModuleMetadata.call(void 0, slot.route.modulePath, server.config.root)));
3001
3091
  const slotContext = await _chunkX333W5KVcjs.resolveFarmRouteContext.call(void 0, farmApp.getConfig(), {
3002
3092
  request: targetRequest,
3003
3093
  params: slot.params,
@@ -3047,7 +3137,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3047
3137
  pageShouldHydrate: shouldHydrate,
3048
3138
  layoutShouldHydrate: shouldHydrateLayout,
3049
3139
  islandStrategy: hydrationIslandStrategy,
3050
- rendering: _chunk3TL3AH25cjs.resolveRouteRenderingConfig.call(void 0, routeModule)
3140
+ rendering: _chunkX4K7TYN6cjs.resolveRouteRenderingConfig.call(void 0, routeModule)
3051
3141
  });
3052
3142
  const destinationLayoutPatterns = layouts.map((layout) => layout.pattern);
3053
3143
  const layoutStartIndex = _chunkO27PLNQZcjs.getSharedLayoutPrefixLength.call(void 0,
@@ -3061,7 +3151,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3061
3151
  middlewareContext,
3062
3152
  () => renderer.renderNavigationFragment({
3063
3153
  PageComponent: routeModule.default,
3064
- LoadingComponent: _optionalChain([loadingModule, 'optionalAccess', _231 => _231.default]),
3154
+ LoadingComponent: _optionalChain([loadingModule, 'optionalAccess', _242 => _242.default]),
3065
3155
  pageProps: routeProps,
3066
3156
  params,
3067
3157
  layouts: layouts.map((layout, index) => ({
@@ -3169,18 +3259,18 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3169
3259
  trustProxy: currentServerConfig.trustProxy
3170
3260
  }).pathname;
3171
3261
  const routeManager2 = farmApp.getRouteManager();
3172
- const hasBeforeRouteMatchHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _232 => _232.hasHook, 'call', _233 => _233("beforeRouteMatch")]), () => ( false));
3173
- const hasAfterRouteMatchHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _234 => _234.hasHook, 'call', _235 => _235("afterRouteMatch")]), () => ( false));
3174
- const hasBeforeRequestHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _236 => _236.hasHook, 'call', _237 => _237("beforeRequest")]), () => ( false));
3175
- const hasBeforeRenderHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _238 => _238.hasHook, 'call', _239 => _239("beforeRender")]), () => ( false));
3176
- const hasAfterResponseHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _240 => _240.hasHook, 'call', _241 => _241("afterResponse")]), () => ( false));
3177
- const hasHTMLTransformHook = (_nullishCoalesce(_optionalChain([pm, 'optionalAccess', _242 => _242.hasHook, 'call', _243 => _243("transformHTML")]), () => ( false))) || (_nullishCoalesce(_optionalChain([pm, 'optionalAccess', _244 => _244.hasHook, 'call', _245 => _245("afterRender")]), () => ( false)));
3178
- const hasRuntimeRequestHooks = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _246 => _246.hasRuntimeRequestHooks, 'call', _247 => _247()]), () => ( false));
3179
- const hasRuntimeAfterHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _248 => _248.hasRuntimeHook, 'call', _249 => _249("after")]), () => ( false));
3262
+ const hasBeforeRouteMatchHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _243 => _243.hasHook, 'call', _244 => _244("beforeRouteMatch")]), () => ( false));
3263
+ const hasAfterRouteMatchHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _245 => _245.hasHook, 'call', _246 => _246("afterRouteMatch")]), () => ( false));
3264
+ const hasBeforeRequestHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _247 => _247.hasHook, 'call', _248 => _248("beforeRequest")]), () => ( false));
3265
+ const hasBeforeRenderHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _249 => _249.hasHook, 'call', _250 => _250("beforeRender")]), () => ( false));
3266
+ const hasAfterResponseHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _251 => _251.hasHook, 'call', _252 => _252("afterResponse")]), () => ( false));
3267
+ const hasHTMLTransformHook = (_nullishCoalesce(_optionalChain([pm, 'optionalAccess', _253 => _253.hasHook, 'call', _254 => _254("transformHTML")]), () => ( false))) || (_nullishCoalesce(_optionalChain([pm, 'optionalAccess', _255 => _255.hasHook, 'call', _256 => _256("afterRender")]), () => ( false)));
3268
+ const hasRuntimeRequestHooks = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _257 => _257.hasRuntimeRequestHooks, 'call', _258 => _258()]), () => ( false));
3269
+ const hasRuntimeAfterHook = _nullishCoalesce(_optionalChain([pm, 'optionalAccess', _259 => _259.hasRuntimeHook, 'call', _260 => _260("after")]), () => ( false));
3180
3270
  const requestedMatch = routeManager2.matchRoute(requestedPathname);
3181
3271
  const pageBuiltInRouteLabel = (pathname2) => {
3182
3272
  const routePathname = _chunkD22BUQKWcjs.stripFarmBasePath.call(void 0, pathname2, farmConfig.basePath);
3183
- const mcpLabel = _chunkDPJ66FSIcjs.resolveFarmMCPRouteLabel.call(void 0, routePathname, apiServerBasePath);
3273
+ const mcpLabel = _chunkXX32BOMMcjs.resolveFarmMCPRouteLabel.call(void 0, routePathname, apiServerBasePath);
3184
3274
  if (mcpLabel) return mcpLabel;
3185
3275
  if (farmAgentGeneratedPaths(farmConfig).includes(routePathname)) return routePathname;
3186
3276
  return routePathname === _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PATH && farmApp.getServerRenderer().getDefaultMCPServer() ? _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PATH : null;
@@ -3192,13 +3282,13 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3192
3282
  createRequestFromNodeRequest(req, new URL(fullUrl)),
3193
3283
  {
3194
3284
  kind: "page",
3195
- route: _chunkDPJ66FSIcjs.setFarmRouteLabel.call(void 0,
3285
+ route: _chunkXX32BOMMcjs.setFarmRouteLabel.call(void 0,
3196
3286
  {
3197
3287
  pathname: requestedPathname,
3198
- pattern: _optionalChain([requestedMatch, 'optionalAccess', _250 => _250.route, 'optionalAccess', _251 => _251.pattern]) || null,
3199
- params: _optionalChain([requestedMatch, 'optionalAccess', _252 => _252.params]) || {}
3288
+ pattern: _optionalChain([requestedMatch, 'optionalAccess', _261 => _261.route, 'optionalAccess', _262 => _262.pattern]) || null,
3289
+ params: _optionalChain([requestedMatch, 'optionalAccess', _263 => _263.params]) || {}
3200
3290
  },
3201
- _optionalChain([requestedMatch, 'optionalAccess', _253 => _253.route]) ? null : pageBuiltInRouteLabel(requestedPathname)
3291
+ _optionalChain([requestedMatch, 'optionalAccess', _264 => _264.route]) ? null : pageBuiltInRouteLabel(requestedPathname)
3202
3292
  )
3203
3293
  }
3204
3294
  );
@@ -3231,17 +3321,17 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3231
3321
  if (pm && hasAfterRouteMatchHook) {
3232
3322
  await pm.runHookParallel("afterRouteMatch", {
3233
3323
  pathname,
3234
- matched: !!_optionalChain([routeMatch, 'optionalAccess', _254 => _254.route]),
3235
- routePattern: _optionalChain([routeMatch, 'optionalAccess', _255 => _255.route, 'optionalAccess', _256 => _256.pattern]) || null,
3236
- params: _optionalChain([routeMatch, 'optionalAccess', _257 => _257.params]) || {},
3237
- layoutPatterns: (_optionalChain([routeMatch, 'optionalAccess', _258 => _258.layouts]) || []).map((l) => l.pattern)
3324
+ matched: !!_optionalChain([routeMatch, 'optionalAccess', _265 => _265.route]),
3325
+ routePattern: _optionalChain([routeMatch, 'optionalAccess', _266 => _266.route, 'optionalAccess', _267 => _267.pattern]) || null,
3326
+ params: _optionalChain([routeMatch, 'optionalAccess', _268 => _268.params]) || {},
3327
+ layoutPatterns: (_optionalChain([routeMatch, 'optionalAccess', _269 => _269.layouts]) || []).map((l) => l.pattern)
3238
3328
  });
3239
3329
  }
3240
3330
  const renderPayload = {
3241
3331
  pathname,
3242
3332
  method,
3243
- routePattern: _optionalChain([routeMatch, 'optionalAccess', _259 => _259.route, 'optionalAccess', _260 => _260.pattern]) || null,
3244
- params: _optionalChain([routeMatch, 'optionalAccess', _261 => _261.params]) || {}
3333
+ routePattern: _optionalChain([routeMatch, 'optionalAccess', _270 => _270.route, 'optionalAccess', _271 => _271.pattern]) || null,
3334
+ params: _optionalChain([routeMatch, 'optionalAccess', _272 => _272.params]) || {}
3245
3335
  };
3246
3336
  const shouldInterceptResponse = Boolean(
3247
3337
  pm && (hasAfterResponseHook || hasHTMLTransformHook || runtimeSession && hasRuntimeAfterHook)
@@ -3263,7 +3353,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3263
3353
  emitError: (error) => emitPluginError("response-end", error, { pathname })
3264
3354
  }) : void 0;
3265
3355
  try {
3266
- if (_optionalChain([middlewareManager, 'optionalAccess', _262 => _262.hasMiddleware, 'call', _263 => _263()])) {
3356
+ if (_optionalChain([middlewareManager, 'optionalAccess', _273 => _273.hasMiddleware, 'call', _274 => _274()])) {
3267
3357
  const middlewareRequest = createRequestFromNodeRequest(req, new URL(fullUrl));
3268
3358
  const handled = await runFarmMiddlewareWithNavigation(
3269
3359
  farmApp.getServerRenderer(),
@@ -3273,7 +3363,7 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3273
3363
  () => middlewareManager.execute(req, res)
3274
3364
  );
3275
3365
  if (handled) {
3276
- if (!_optionalChain([responseInterceptor, 'optionalAccess', _264 => _264.isEnded, 'call', _265 => _265()])) {
3366
+ if (!_optionalChain([responseInterceptor, 'optionalAccess', _275 => _275.isEnded, 'call', _276 => _276()])) {
3277
3367
  const duration = Date.now() - startTime;
3278
3368
  logResponse(method, urlPath, res.statusCode || 200, duration, "PAGE");
3279
3369
  }
@@ -3286,14 +3376,14 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3286
3376
  req.url || "/",
3287
3377
  `http://${req.headers.host || "localhost:3000"}`
3288
3378
  ).pathname;
3289
- const hasLocalPageRoute = Boolean(_optionalChain([routeManager2, 'access', _266 => _266.matchRoute, 'call', _267 => _267(currentPathname), 'optionalAccess', _268 => _268.route]));
3379
+ const hasLocalPageRoute = Boolean(_optionalChain([routeManager2, 'access', _277 => _277.matchRoute, 'call', _278 => _278(currentPathname), 'optionalAccess', _279 => _279.route]));
3290
3380
  await pm.runHookParallelFiltered(
3291
3381
  "beforeRequest",
3292
3382
  (plugin) => !hasLocalPageRoute || plugin.name !== _chunkUYTAP4FQcjs.FARM_CONFIG_REWRITES_PLUGIN_NAME,
3293
3383
  req,
3294
3384
  res
3295
3385
  );
3296
- if (runtimeSession && req.url !== urlBeforeRequestHooks && _optionalChain([req, 'access', _269 => _269.url, 'optionalAccess', _270 => _270.startsWith, 'call', _271 => _271("/")]) && !res.writableEnded) {
3386
+ if (runtimeSession && req.url !== urlBeforeRequestHooks && _optionalChain([req, 'access', _280 => _280.url, 'optionalAccess', _281 => _281.startsWith, 'call', _282 => _282("/")]) && !res.writableEnded) {
3297
3387
  const destinationUrl = new URL(req.url, fullUrl);
3298
3388
  const destinationMatch = routeManager2.matchRoute(destinationUrl.pathname);
3299
3389
  const guarded = await pm.runRuntimeBeforeForRewrite(
@@ -3303,8 +3393,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3303
3393
  kind: "page",
3304
3394
  route: {
3305
3395
  pathname: destinationUrl.pathname,
3306
- pattern: _optionalChain([destinationMatch, 'optionalAccess', _272 => _272.route, 'optionalAccess', _273 => _273.pattern]) || null,
3307
- params: _optionalChain([destinationMatch, 'optionalAccess', _274 => _274.params]) || {}
3396
+ pattern: _optionalChain([destinationMatch, 'optionalAccess', _283 => _283.route, 'optionalAccess', _284 => _284.pattern]) || null,
3397
+ params: _optionalChain([destinationMatch, 'optionalAccess', _285 => _285.params]) || {}
3308
3398
  }
3309
3399
  }
3310
3400
  );
@@ -3316,8 +3406,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3316
3406
  }
3317
3407
  }
3318
3408
  }
3319
- if (res.writableEnded || _optionalChain([responseInterceptor, 'optionalAccess', _275 => _275.isEnded, 'call', _276 => _276()]) || await proxyFarmExternalRewrite(req, res, currentServerConfig.bodySizeLimit)) {
3320
- if (!_optionalChain([responseInterceptor, 'optionalAccess', _277 => _277.isEnded, 'call', _278 => _278()])) {
3409
+ if (res.writableEnded || _optionalChain([responseInterceptor, 'optionalAccess', _286 => _286.isEnded, 'call', _287 => _287()]) || await proxyFarmExternalRewrite(req, res, currentServerConfig.bodySizeLimit)) {
3410
+ if (!_optionalChain([responseInterceptor, 'optionalAccess', _288 => _288.isEnded, 'call', _289 => _289()])) {
3321
3411
  const duration = Date.now() - startTime;
3322
3412
  logResponse(method, urlPath, res.statusCode || 200, duration, "PAGE");
3323
3413
  }
@@ -3381,8 +3471,8 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3381
3471
  if (imageModule) return imageModule;
3382
3472
  }
3383
3473
  if (_chunkE7QOEV5Zcjs.parseProgrammaticRouteModuleId.call(void 0, id)) {
3384
- const renderer = _optionalChain([farmApp, 'optionalAccess', _279 => _279.getConfig, 'call', _280 => _280(), 'access', _281 => _281.renderer]) || _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, options.renderer);
3385
- const root = _optionalChain([server, 'optionalAccess', _282 => _282.config, 'access', _283 => _283.root]) || options.root;
3474
+ const renderer = _optionalChain([farmApp, 'optionalAccess', _290 => _290.getConfig, 'call', _291 => _291(), 'access', _292 => _292.renderer]) || _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, options.renderer);
3475
+ const root = _optionalChain([server, 'optionalAccess', _293 => _293.config, 'access', _294 => _294.root]) || options.root;
3386
3476
  if (isClientEnvironment(this, loadOptions)) {
3387
3477
  return generateProgrammaticClientRouteModuleForId(
3388
3478
  id,
@@ -3398,65 +3488,65 @@ window.__FARM_MANIFEST__ = ${inlineValue({
3398
3488
  return FARM_DEV_CLIENT_BOOT_MODULE;
3399
3489
  }
3400
3490
  if (isFarmClientVirtualId(id)) {
3401
- const resolvedConfig = _optionalChain([farmApp, 'optionalAccess', _284 => _284.getConfig, 'call', _285 => _285()]);
3402
- const renderer = _optionalChain([resolvedConfig, 'optionalAccess', _286 => _286.renderer]) || _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, options.renderer);
3403
- const integrations = _optionalChain([resolvedConfig, 'optionalAccess', _287 => _287.integrations]) || options.integrations;
3404
- const root = _optionalChain([resolvedConfig, 'optionalAccess', _288 => _288.root]) || _optionalChain([server, 'optionalAccess', _289 => _289.config, 'access', _290 => _290.root]) || process.cwd();
3405
- const docs = _optionalChain([resolvedConfig, 'optionalAccess', _291 => _291.docs]);
3491
+ const resolvedConfig = _optionalChain([farmApp, 'optionalAccess', _295 => _295.getConfig, 'call', _296 => _296()]);
3492
+ const renderer = _optionalChain([resolvedConfig, 'optionalAccess', _297 => _297.renderer]) || _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, options.renderer);
3493
+ const integrations = _optionalChain([resolvedConfig, 'optionalAccess', _298 => _298.integrations]) || options.integrations;
3494
+ const root = _optionalChain([resolvedConfig, 'optionalAccess', _299 => _299.root]) || _optionalChain([server, 'optionalAccess', _300 => _300.config, 'access', _301 => _301.root]) || process.cwd();
3495
+ const docs = _optionalChain([resolvedConfig, 'optionalAccess', _302 => _302.docs]);
3406
3496
  const adapterOwnsDocsRuntime = Boolean(
3407
- _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) && _optionalChain([docs, 'optionalAccess', _292 => _292.adapter, 'optionalAccess', _293 => _293.server]) && docs.adapter.react
3497
+ _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) && _optionalChain([docs, 'optionalAccess', _303 => _303.adapter, 'optionalAccess', _304 => _304.server]) && docs.adapter.react
3408
3498
  );
3409
- const devtools = _nullishCoalesce(_optionalChain([resolvedConfig, 'optionalAccess', _294 => _294.devtools]), () => ( _chunkSTF6VDYQcjs.resolveFarmDevtoolsConfig.call(void 0, false, "production")));
3499
+ const devtools = _nullishCoalesce(_optionalChain([resolvedConfig, 'optionalAccess', _305 => _305.devtools]), () => ( _chunkSTF6VDYQcjs.resolveFarmDevtoolsConfig.call(void 0, false, "production")));
3410
3500
  const [docsRuntime, docsSearchRuntime, devtoolsClientRuntime] = await Promise.all([
3411
- _optionalChain([docs, 'optionalAccess', _295 => _295.enabled]) ? loadFarmDocsDevRuntime() : null,
3412
- _optionalChain([docs, 'optionalAccess', _296 => _296.enabled]) && !adapterOwnsDocsRuntime ? loadFarmDocsSearchDevRuntime() : null,
3501
+ _optionalChain([docs, 'optionalAccess', _306 => _306.enabled]) ? loadFarmDocsDevRuntime() : null,
3502
+ _optionalChain([docs, 'optionalAccess', _307 => _307.enabled]) && !adapterOwnsDocsRuntime ? loadFarmDocsSearchDevRuntime() : null,
3413
3503
  devtools.enabled ? loadFarmDevtoolsClientRuntime() : null
3414
3504
  ]);
3415
- const docsSearchEnabled = _nullishCoalesce(_optionalChain([docsSearchRuntime, 'optionalAccess', _297 => _297.isFarmDocsSearchEnabled, 'call', _298 => _298(docs)]), () => ( false));
3505
+ const docsSearchEnabled = _nullishCoalesce(_optionalChain([docsSearchRuntime, 'optionalAccess', _308 => _308.isFarmDocsSearchEnabled, 'call', _309 => _309(docs)]), () => ( false));
3416
3506
  const generatedDocsSearchRuntime = docsSearchRuntime ? docsSearchRuntime.generateFarmDocsSearchClientRuntime(
3417
3507
  docsSearchEnabled,
3418
3508
  docsSearchEnabled ? docsSearchRuntime.resolveFarmDocsSearchClientModule(root) : void 0
3419
3509
  ) : EMPTY_FARM_DOCS_SEARCH_CLIENT_RUNTIME;
3420
3510
  const generatedDevtoolsClientRuntime = devtoolsClientRuntime ? devtoolsClientRuntime.generateFarmDevtoolsClientRuntime(devtools) : "";
3421
3511
  const generatedDevIndicatorsClientRuntime = farmApp ? _chunkBPNOYILCcjs.generateFarmDevIndicatorsClientRuntime.call(void 0, farmApp.getConfig().devIndicators) : "";
3422
- const integrationProviders = _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) ? _chunkZP32GNJQcjs.getIntegrationProviders.call(void 0, integrations) : [];
3423
- const isolatedHydrationMode = _chunkUYSTTPYJcjs.resolveFarmIsolatedClientHydrationMode.call(void 0,
3424
- _optionalChain([resolvedConfig, 'optionalAccess', _299 => _299.experimental, 'optionalAccess', _300 => _300.isolatedClientHydration]),
3512
+ const integrationProviders = _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) ? _chunkI32V5CZLcjs.getIntegrationProviders.call(void 0, integrations) : [];
3513
+ const isolatedHydrationMode = _chunkGGNJAGGEcjs.resolveFarmIsolatedClientHydrationMode.call(void 0,
3514
+ _optionalChain([resolvedConfig, 'optionalAccess', _310 => _310.experimental, 'optionalAccess', _311 => _311.isolatedClientHydration]),
3425
3515
  {
3426
- serverComponents: _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([resolvedConfig, 'optionalAccess', _301 => _301.experimental, 'optionalAccess', _302 => _302.serverComponents])) === "rsc",
3516
+ serverComponents: _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([resolvedConfig, 'optionalAccess', _312 => _312.experimental, 'optionalAccess', _313 => _313.serverComponents])) === "rsc",
3427
3517
  hasUnsupportedIntegrationProvider: integrationProviders.filter((provider) => provider.component || provider.type === "clerk").some((provider) => provider.supportsIsolatedHydration !== true)
3428
3518
  }
3429
3519
  );
3430
3520
  return generateClientCode(
3431
3521
  integrationProviders,
3432
3522
  [
3433
- ..._chunkZP32GNJQcjs.getIntegrationDocumentNavigationMatchers.call(void 0, integrations),
3434
- ..._nullishCoalesce(_optionalChain([docsRuntime, 'optionalAccess', _303 => _303.getFarmDocsDocumentNavigationMatchers, 'call', _304 => _304(docs)]), () => ( []))
3523
+ ..._chunkI32V5CZLcjs.getIntegrationDocumentNavigationMatchers.call(void 0, integrations),
3524
+ ..._nullishCoalesce(_optionalChain([docsRuntime, 'optionalAccess', _314 => _314.getFarmDocsDocumentNavigationMatchers, 'call', _315 => _315(docs)]), () => ( []))
3435
3525
  ],
3436
3526
  generatedDocsSearchRuntime,
3437
3527
  `${generatedDevtoolsClientRuntime}
3438
3528
  ${generatedDevIndicatorsClientRuntime}`,
3439
- _optionalChain([resolvedConfig, 'optionalAccess', _305 => _305.plugins]) || [],
3529
+ _optionalChain([resolvedConfig, 'optionalAccess', _316 => _316.plugins]) || [],
3440
3530
  root,
3441
- _optionalChain([resolvedConfig, 'optionalAccess', _306 => _306.srcDir]) || options.srcDir || "src",
3442
- _optionalChain([resolvedConfig, 'optionalAccess', _307 => _307.publicRuntimeConfig]) || options.publicRuntimeConfig,
3443
- _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) ? _optionalChain([docs, 'optionalAccess', _308 => _308.adapter, 'optionalAccess', _309 => _309.react]) : void 0,
3531
+ _optionalChain([resolvedConfig, 'optionalAccess', _317 => _317.srcDir]) || options.srcDir || "src",
3532
+ _optionalChain([resolvedConfig, 'optionalAccess', _318 => _318.publicRuntimeConfig]) || options.publicRuntimeConfig,
3533
+ _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) ? _optionalChain([docs, 'optionalAccess', _319 => _319.adapter, 'optionalAccess', _320 => _320.react]) : void 0,
3444
3534
  renderer,
3445
- isolatedHydrationMode === "enabled" || _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) && _optionalChain([(_nullishCoalesce(options.isolatedClientBoundaryModules, () => ( _optionalChain([farmApp, 'optionalAccess', _310 => _310.getRouteManager, 'call', _311 => _311(), 'access', _312 => _312.getIsolatedClientBoundaryModules, 'call', _313 => _313(root)])))), 'optionalAccess', _314 => _314.size]) > 0,
3446
- _nullishCoalesce(_optionalChain([resolvedConfig, 'optionalAccess', _315 => _315.trailingSlash]), () => ( false)),
3447
- _nullishCoalesce(_optionalChain([resolvedConfig, 'optionalAccess', _316 => _316.basePath]), () => ( "/")),
3448
- _chunkUYSTTPYJcjs.generateClientCachePersistenceCode.call(void 0,
3449
- _chunkUYSTTPYJcjs.resolveFarmClientCacheAdapterEntry.call(void 0, root, _optionalChain([resolvedConfig, 'optionalAccess', _317 => _317.cache]))
3535
+ isolatedHydrationMode === "enabled" || _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) && _optionalChain([(_nullishCoalesce(options.isolatedClientBoundaryModules, () => ( _optionalChain([farmApp, 'optionalAccess', _321 => _321.getRouteManager, 'call', _322 => _322(), 'access', _323 => _323.getIsolatedClientBoundaryModules, 'call', _324 => _324(root)])))), 'optionalAccess', _325 => _325.size]) > 0,
3536
+ _nullishCoalesce(_optionalChain([resolvedConfig, 'optionalAccess', _326 => _326.trailingSlash]), () => ( false)),
3537
+ _nullishCoalesce(_optionalChain([resolvedConfig, 'optionalAccess', _327 => _327.basePath]), () => ( "/")),
3538
+ _chunkGGNJAGGEcjs.generateClientCachePersistenceCode.call(void 0,
3539
+ _chunkGGNJAGGEcjs.resolveFarmClientCacheAdapterEntry.call(void 0, root, _optionalChain([resolvedConfig, 'optionalAccess', _328 => _328.cache]))
3450
3540
  ),
3451
3541
  _chunkRD623KW4cjs.isReactRenderer.call(void 0, renderer) ? _chunkSM2SYWARcjs.getFarmDocsAdapterConfigModule.call(void 0, docs) : void 0,
3452
- _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([resolvedConfig, 'optionalAccess', _318 => _318.experimental, 'optionalAccess', _319 => _319.serverComponents])) === "islands"
3542
+ _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([resolvedConfig, 'optionalAccess', _329 => _329.experimental, 'optionalAccess', _330 => _330.serverComponents])) === "islands"
3453
3543
  );
3454
3544
  }
3455
3545
  if (id === "/@farm/server") {
3456
3546
  return generateServerCode();
3457
3547
  }
3458
3548
  if (id === "/@farm/manifest") {
3459
- const routeManager = _optionalChain([farmApp, 'optionalAccess', _320 => _320.getRouteManager, 'call', _321 => _321()]);
3549
+ const routeManager = _optionalChain([farmApp, 'optionalAccess', _331 => _331.getRouteManager, 'call', _332 => _332()]);
3460
3550
  if (!routeManager) {
3461
3551
  return `
3462
3552
  export const getManifest = () => ({
@@ -3469,9 +3559,9 @@ export const getManifest = () => ({
3469
3559
  `;
3470
3560
  }
3471
3561
  const manifest = routeManager.generateClientManifest(server.config.root);
3472
- const globalStylesheetHref = _chunkUYSTTPYJcjs.resolveDevGlobalStylesheetHref.call(void 0,
3562
+ const globalStylesheetHref = _chunkGGNJAGGEcjs.resolveDevGlobalStylesheetHref.call(void 0,
3473
3563
  server.config.root,
3474
- _optionalChain([farmApp, 'optionalAccess', _322 => _322.getConfig, 'call', _323 => _323(), 'access', _324 => _324.srcDir])
3564
+ _optionalChain([farmApp, 'optionalAccess', _333 => _333.getConfig, 'call', _334 => _334(), 'access', _335 => _335.srcDir])
3475
3565
  );
3476
3566
  const fullManifest = {
3477
3567
  clientEntry: "/@farm/client.js",
@@ -3527,53 +3617,75 @@ export const manifest = getManifest();
3527
3617
  }
3528
3618
  },
3529
3619
  async transform(code, id, transformOptions) {
3530
- const actionConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _325 => _325.getConfig, 'call', _326 => _326()]), () => ( options));
3620
+ const actionConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _336 => _336.getConfig, 'call', _337 => _337()]), () => ( options));
3621
+ let rewrotePackageImports = false;
3622
+ if (_chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([actionConfig, 'access', _338 => _338.experimental, 'optionalAccess', _339 => _339.serverComponents])) === "islands" && !id.includes("/node_modules/") && !id.startsWith("\0") && /\.[cm]?[jt]sx?(?:$|\?)/.test(id) && !_chunkGGNJAGGEcjs.hasUseClientDirective.call(void 0, code)) {
3623
+ const file = id.split("?", 1)[0];
3624
+ const projectRoot = actionConfig.root || _optionalChain([server, 'optionalAccess', _340 => _340.config, 'access', _341 => _341.root]) || process.cwd();
3625
+ const referenced = _chunkGGNJAGGEcjs.rewriteFarmPackageClientImports.call(void 0, {
3626
+ code,
3627
+ file,
3628
+ root: projectRoot,
3629
+ isClientPackage: (specifier) => _chunkGGNJAGGEcjs.isFarmPackageClientBoundary.call(void 0, file, specifier, projectRoot)
3630
+ });
3631
+ if (referenced !== null) {
3632
+ code = referenced;
3633
+ rewrotePackageImports = true;
3634
+ }
3635
+ if (_optionalChain([transformOptions, 'optionalAccess', _342 => _342.ssr]) === true) {
3636
+ const cached = rewriteFarmReactCacheImport(code, file);
3637
+ if (cached !== null) {
3638
+ code = cached;
3639
+ rewrotePackageImports = true;
3640
+ }
3641
+ }
3642
+ }
3531
3643
  if (islandsServerFns() && !_chunkPIUTGRDIcjs.isFarmServerFnBoundaryId.call(void 0, id) && !id.includes("/node_modules/") && /\.[cm]?[jt]sx?(?:$|\?)/.test(id)) {
3532
3644
  const serverFns = _chunkPIUTGRDIcjs.transformFarmServerFns.call(void 0, code, id, {
3533
- environment: _optionalChain([transformOptions, 'optionalAccess', _327 => _327.ssr]) === true ? "rsc" : "client"
3645
+ environment: _optionalChain([transformOptions, 'optionalAccess', _343 => _343.ssr]) === true ? "rsc" : "client"
3534
3646
  });
3535
3647
  if (serverFns) {
3536
3648
  if (!serverFns.code.includes("use server")) return { code: serverFns.code, map: null };
3537
3649
  code = serverFns.code;
3538
3650
  }
3539
3651
  }
3540
- if (_chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([actionConfig, 'access', _328 => _328.experimental, 'optionalAccess', _329 => _329.serverComponents])) === "islands" && code.includes("use server") && !id.includes("/node_modules/") && /\.[cm]?[jt]sx?(?:$|\?)/.test(id)) {
3652
+ if (_chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([actionConfig, 'access', _344 => _344.experimental, 'optionalAccess', _345 => _345.serverComponents])) === "islands" && code.includes("use server") && !id.includes("/node_modules/") && /\.[cm]?[jt]sx?(?:$|\?)/.test(id)) {
3541
3653
  const file = id.split("?", 1)[0];
3542
3654
  const actionModule = transformFarmFormActionModule({
3543
3655
  code,
3544
3656
  id,
3545
- root: actionConfig.root || _optionalChain([server, 'optionalAccess', _330 => _330.config, 'access', _331 => _331.root]) || process.cwd(),
3546
- ssr: _optionalChain([transformOptions, 'optionalAccess', _332 => _332.ssr]) === true,
3657
+ root: actionConfig.root || _optionalChain([server, 'optionalAccess', _346 => _346.config, 'access', _347 => _347.root]) || process.cwd(),
3658
+ ssr: _optionalChain([transformOptions, 'optionalAccess', _348 => _348.ssr]) === true,
3547
3659
  // Parsed by file type: page components are TSX.
3548
3660
  parse: (source) => _vite.parseSync.call(void 0, file, source).program
3549
3661
  });
3550
3662
  if (actionModule) return { code: actionModule, map: null };
3551
3663
  }
3552
- if (!_optionalChain([transformOptions, 'optionalAccess', _333 => _333.ssr])) {
3553
- const docsConfigModule = _chunkSM2SYWARcjs.getFarmDocsAdapterConfigModule.call(void 0, _optionalChain([farmApp, 'optionalAccess', _334 => _334.getConfig, 'call', _335 => _335(), 'optionalAccess', _336 => _336.docs]));
3554
- if (_chunkUYSTTPYJcjs.isFarmDocsClientConfigModule.call(void 0, id, docsConfigModule)) {
3555
- const redacted = _chunkUYSTTPYJcjs.redactFarmDocsClientConfig.call(void 0, code, id.split("?")[0]);
3664
+ if (!_optionalChain([transformOptions, 'optionalAccess', _349 => _349.ssr])) {
3665
+ const docsConfigModule = _chunkSM2SYWARcjs.getFarmDocsAdapterConfigModule.call(void 0, _optionalChain([farmApp, 'optionalAccess', _350 => _350.getConfig, 'call', _351 => _351(), 'optionalAccess', _352 => _352.docs]));
3666
+ if (_chunkGGNJAGGEcjs.isFarmDocsClientConfigModule.call(void 0, id, docsConfigModule)) {
3667
+ const redacted = _chunkGGNJAGGEcjs.redactFarmDocsClientConfig.call(void 0, code, id.split("?")[0]);
3556
3668
  if (redacted !== null) return { code: redacted, map: null };
3557
3669
  }
3558
3670
  }
3559
- if (!_optionalChain([transformOptions, 'optionalAccess', _337 => _337.ssr])) {
3560
- const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _338 => _338.getConfig, 'call', _339 => _339()]), () => ( options));
3561
- if ((_optionalChain([currentConfig, 'access', _340 => _340.experimental, 'optionalAccess', _341 => _341.serverActions]) !== true || !serverFnTransformActive) && !islandsServerFns()) {
3671
+ if (!_optionalChain([transformOptions, 'optionalAccess', _353 => _353.ssr])) {
3672
+ const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _354 => _354.getConfig, 'call', _355 => _355()]), () => ( options));
3673
+ if ((_optionalChain([currentConfig, 'access', _356 => _356.experimental, 'optionalAccess', _357 => _357.serverActions]) !== true || !serverFnTransformActive) && !islandsServerFns()) {
3562
3674
  const violation = findClientServerFnViolation(code, id);
3563
3675
  if (violation) {
3564
3676
  this.error(formatServerFnBoundaryError(violation, id));
3565
3677
  }
3566
3678
  }
3567
3679
  }
3568
- if (!_optionalChain([transformOptions, 'optionalAccess', _342 => _342.ssr]) && shouldInspectClientBoundary(id, code)) {
3569
- warnClientBoundaryOnce(this, id, code, _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _343 => _343.getConfig, 'call', _344 => _344()]), () => ( options)));
3680
+ if (!_optionalChain([transformOptions, 'optionalAccess', _358 => _358.ssr]) && shouldInspectClientBoundary(id, code)) {
3681
+ warnClientBoundaryOnce(this, id, code, _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _359 => _359.getConfig, 'call', _360 => _360()]), () => ( options)));
3570
3682
  }
3571
3683
  if (typeof imageImports.transform === "function") {
3572
3684
  const imageModule = await imageImports.transform.call(this, code, id, transformOptions);
3573
3685
  if (imageModule) return imageModule;
3574
3686
  }
3575
3687
  let transformedCode = code;
3576
- let transformed = false;
3688
+ let transformed = rewrotePackageImports;
3577
3689
  if (typeof fontImports.transform === "function") {
3578
3690
  const fontResult = await fontImports.transform.call(
3579
3691
  this,
@@ -3581,13 +3693,13 @@ export const manifest = getManifest();
3581
3693
  id,
3582
3694
  transformOptions
3583
3695
  );
3584
- const fontCode = typeof fontResult === "string" ? fontResult : _optionalChain([fontResult, 'optionalAccess', _345 => _345.code, 'optionalAccess', _346 => _346.toString, 'call', _347 => _347()]);
3696
+ const fontCode = typeof fontResult === "string" ? fontResult : _optionalChain([fontResult, 'optionalAccess', _361 => _361.code, 'optionalAccess', _362 => _362.toString, 'call', _363 => _363()]);
3585
3697
  if (fontCode) {
3586
3698
  transformedCode = fontCode;
3587
3699
  transformed = true;
3588
3700
  }
3589
3701
  }
3590
- if (_optionalChain([transformOptions, 'optionalAccess', _348 => _348.ssr]) && server) {
3702
+ if (_optionalChain([transformOptions, 'optionalAccess', _364 => _364.ssr]) && server) {
3591
3703
  const rewrittenImports = rewriteEarlySsrRelativeImports({
3592
3704
  code: transformedCode,
3593
3705
  id,
@@ -3599,28 +3711,28 @@ export const manifest = getManifest();
3599
3711
  transformed = true;
3600
3712
  }
3601
3713
  }
3602
- if (_chunkUYSTTPYJcjs.hasUseClientDirective.call(void 0, transformedCode)) {
3714
+ if (_chunkGGNJAGGEcjs.hasUseClientDirective.call(void 0, transformedCode)) {
3603
3715
  const clientBoundarySource = transformedCode;
3604
3716
  const moduleInfo = this.getModuleInfo(id);
3605
3717
  if (moduleInfo) {
3606
3718
  moduleInfo.isClientComponent = true;
3607
3719
  }
3608
- transformedCode = _chunkUYSTTPYJcjs.stripUseClientDirective.call(void 0, transformedCode);
3720
+ transformedCode = _chunkGGNJAGGEcjs.stripUseClientDirective.call(void 0, transformedCode);
3609
3721
  transformed = true;
3610
- const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _349 => _349.getConfig, 'call', _350 => _350()]), () => ( options));
3722
+ const currentConfig = _nullishCoalesce(_optionalChain([farmApp, 'optionalAccess', _365 => _365.getConfig, 'call', _366 => _366()]), () => ( options));
3611
3723
  let isolatedModuleReference = null;
3612
- const root = currentConfig.root || _optionalChain([server, 'optionalAccess', _351 => _351.config, 'access', _352 => _352.root]) || process.cwd();
3724
+ const root = currentConfig.root || _optionalChain([server, 'optionalAccess', _367 => _367.config, 'access', _368 => _368.root]) || process.cwd();
3613
3725
  const cleanId = id.split("?", 1)[0];
3614
- const selectedIsolatedModules = _nullishCoalesce(options.isolatedClientBoundaryModules, () => ( _optionalChain([farmApp, 'optionalAccess', _353 => _353.getRouteManager, 'call', _354 => _354(), 'access', _355 => _355.getIsolatedClientBoundaryModules, 'call', _356 => _356(root)])));
3615
- const selectedForIsolatedHydration = _optionalChain([selectedIsolatedModules, 'optionalAccess', _357 => _357.has, 'call', _358 => _358(path5.resolve(cleanId))]) === true;
3616
- if (_chunkRD623KW4cjs.isReactRenderer.call(void 0, _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, currentConfig.renderer)) && selectedForIsolatedHydration && _chunkUYSTTPYJcjs.isIsolatableClientBoundarySource.call(void 0, clientBoundarySource)) {
3726
+ const selectedIsolatedModules = _nullishCoalesce(options.isolatedClientBoundaryModules, () => ( _optionalChain([farmApp, 'optionalAccess', _369 => _369.getRouteManager, 'call', _370 => _370(), 'access', _371 => _371.getIsolatedClientBoundaryModules, 'call', _372 => _372(root)])));
3727
+ const selectedForIsolatedHydration = _optionalChain([selectedIsolatedModules, 'optionalAccess', _373 => _373.has, 'call', _374 => _374(path6.resolve(cleanId))]) === true;
3728
+ if (_chunkRD623KW4cjs.isReactRenderer.call(void 0, _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, currentConfig.renderer)) && selectedForIsolatedHydration && _chunkGGNJAGGEcjs.isIsolatableClientBoundarySource.call(void 0, clientBoundarySource)) {
3617
3729
  isolatedModuleReference = _chunkQMNWKQL4cjs.toViteModuleId.call(void 0, cleanId, root);
3618
- const islandsMode = _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([currentConfig, 'access', _359 => _359.experimental, 'optionalAccess', _360 => _360.serverComponents])) === "islands";
3619
- const explicitStrategy = _chunkUYSTTPYJcjs.getIslandStrategyExport.call(void 0, clientBoundarySource);
3620
- const inference = islandsMode && explicitStrategy === null ? _chunkUYSTTPYJcjs.inferFarmIslandStrategy.call(void 0, cleanId, root) : null;
3730
+ const islandsMode = _chunkBPNOYILCcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([currentConfig, 'access', _375 => _375.experimental, 'optionalAccess', _376 => _376.serverComponents])) === "islands";
3731
+ const explicitStrategy = _chunkGGNJAGGEcjs.getIslandStrategyExport.call(void 0, clientBoundarySource);
3732
+ const inference = islandsMode && explicitStrategy === null ? _chunkGGNJAGGEcjs.inferFarmIslandStrategy.call(void 0, cleanId, root) : null;
3621
3733
  if (inference) {
3622
3734
  for (const file of inference.files) {
3623
- if (file !== path5.resolve(cleanId)) this.addWatchFile(file);
3735
+ if (file !== path6.resolve(cleanId)) this.addWatchFile(file);
3624
3736
  recordFarmIslandInferenceDependency(file, cleanId);
3625
3737
  }
3626
3738
  }
@@ -3630,7 +3742,7 @@ export const manifest = getManifest();
3630
3742
  islandStrategy: _nullishCoalesce(explicitStrategy, () => ( "load")),
3631
3743
  parse: (source) => this.parse(source),
3632
3744
  slots: islandsMode,
3633
- inferredInteraction: _optionalChain([inference, 'optionalAccess', _361 => _361.strategy]) === "interaction"
3745
+ inferredInteraction: _optionalChain([inference, 'optionalAccess', _377 => _377.strategy]) === "interaction"
3634
3746
  });
3635
3747
  if (!transformedBoundary) {
3636
3748
  this.error(
@@ -3660,7 +3772,7 @@ export const manifest = getManifest();
3660
3772
  );
3661
3773
  return;
3662
3774
  }` : "";
3663
- const hmrCode = _optionalChain([transformOptions, 'optionalAccess', _362 => _362.ssr]) || reactRefreshActive || !shouldEmitFarmClientRootHmr(currentConfig.renderer) ? "" : `
3775
+ const hmrCode = _optionalChain([transformOptions, 'optionalAccess', _378 => _378.ssr]) || reactRefreshActive || !shouldEmitFarmClientRootHmr(currentConfig.renderer) ? "" : `
3664
3776
  if (import.meta.hot) {
3665
3777
  import.meta.hot.accept((newModule) => {
3666
3778
  ${isolatedHmrUpdate}
@@ -3715,14 +3827,14 @@ if (import.meta.hot) {
3715
3827
  }
3716
3828
  _chunkQMNWKQL4cjs.logger.info(`Found ${ssgPages.length} SSG pages, ${ssrRoutes.length} SSR routes`);
3717
3829
  _chunkQMNWKQL4cjs.logger.info("Pre-rendering SSG pages...");
3718
- const outDir = path5.join(_optionalChain([server, 'optionalAccess', _363 => _363.config, 'access', _364 => _364.root]) || process.cwd(), options.outDir || "dist");
3719
- const clientDir = path5.join(outDir, "client");
3830
+ const outDir = path6.join(_optionalChain([server, 'optionalAccess', _379 => _379.config, 'access', _380 => _380.root]) || process.cwd(), options.outDir || "dist");
3831
+ const clientDir = path6.join(outDir, "client");
3720
3832
  for (const page of ssgPages) {
3721
3833
  try {
3722
3834
  const staticRequest = new Request(new URL(page.urlPath, "http://farm.static"));
3723
3835
  await farmApp.getServerRenderer().runWithRequestContext(staticRequest, async () => {
3724
3836
  const mod = await routeManager.loadRouteModule(page.filePath);
3725
- if (!_optionalChain([mod, 'optionalAccess', _365 => _365.default])) return;
3837
+ if (!_optionalChain([mod, 'optionalAccess', _381 => _381.default])) return;
3726
3838
  const { layouts } = routeManager.matchRoute(page.urlPath);
3727
3839
  const layoutModules = await Promise.all(
3728
3840
  layouts.map((l) => routeManager.loadLayoutModule(l.modulePath))
@@ -3754,7 +3866,7 @@ if (import.meta.hot) {
3754
3866
  const i18nSnapshot = _chunkRVGLYMJMcjs.getFarmI18nClientSnapshot.call(void 0, );
3755
3867
  const i18nHead = renderFarmI18nStaticHead(page.urlPath, i18nSnapshot);
3756
3868
  const fullHtml = `<!DOCTYPE html>
3757
- <html lang="${escapeFarmHtmlAttribute(_optionalChain([i18nSnapshot, 'optionalAccess', _366 => _366.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}>
3869
+ <html lang="${escapeFarmHtmlAttribute(_optionalChain([i18nSnapshot, 'optionalAccess', _382 => _382.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}>
3758
3870
  <head>
3759
3871
  <meta charset="utf-8">
3760
3872
  <meta name="viewport" content="width=device-width, initial-scale=1">
@@ -3768,8 +3880,8 @@ if (import.meta.hot) {
3768
3880
  <script type="module" src="/assets/client.js"></script>
3769
3881
  </body>
3770
3882
  </html>`;
3771
- const outputPath = page.urlPath === "/" ? path5.join(clientDir, "index.html") : path5.join(clientDir, page.urlPath + ".html");
3772
- fs2.mkdirSync(path5.dirname(outputPath), { recursive: true });
3883
+ const outputPath = page.urlPath === "/" ? path6.join(clientDir, "index.html") : path6.join(clientDir, page.urlPath + ".html");
3884
+ fs2.mkdirSync(path6.dirname(outputPath), { recursive: true });
3773
3885
  fs2.writeFileSync(outputPath, fullHtml);
3774
3886
  const revalidateInfo = page.revalidate ? ` (revalidate: ${page.revalidate}s)` : "";
3775
3887
  _chunkQMNWKQL4cjs.logger.success(` \u2713 ${page.urlPath}${revalidateInfo}`);
@@ -3778,7 +3890,7 @@ if (import.meta.hot) {
3778
3890
  _chunkQMNWKQL4cjs.logger.error(` \u2717 ${page.urlPath}: ${error}`);
3779
3891
  }
3780
3892
  }
3781
- const manifestPath = path5.join(outDir, "__ssg_manifest.json");
3893
+ const manifestPath = path6.join(outDir, "__ssg_manifest.json");
3782
3894
  fs2.writeFileSync(
3783
3895
  manifestPath,
3784
3896
  JSON.stringify(
@@ -3812,29 +3924,29 @@ if (import.meta.hot) {
3812
3924
  });
3813
3925
  }
3814
3926
  }
3815
- for (const island of _nullishCoalesce(farmIslandInferenceDependents.get(path5.resolve(file)), () => ( []))) {
3816
- if (island === path5.resolve(file)) continue;
3927
+ for (const island of _nullishCoalesce(farmIslandInferenceDependents.get(path6.resolve(file)), () => ( []))) {
3928
+ if (island === path6.resolve(file)) continue;
3817
3929
  for (const mod of _nullishCoalesce(server2.moduleGraph.getModulesByFile(_chunkQMNWKQL4cjs.toPosixPath.call(void 0, island)), () => ( []))) {
3818
3930
  server2.moduleGraph.invalidateModule(mod);
3819
3931
  }
3820
3932
  }
3821
- const currentFarmConfig = _optionalChain([farmApp, 'optionalAccess', _367 => _367.getConfig, 'call', _368 => _368()]);
3933
+ const currentFarmConfig = _optionalChain([farmApp, 'optionalAccess', _383 => _383.getConfig, 'call', _384 => _384()]);
3822
3934
  const normalizedFile = file.replace(/\\/g, "/");
3823
3935
  if (currentFarmConfig && /\/route\.(?:ts|tsx|js|jsx)$/.test(normalizedFile) && _chunk5Y2P454Ocjs.getFarmAppDirectories.call(void 0, currentFarmConfig).some(
3824
3936
  (appDir) => normalizedFile.startsWith(`${_chunkQMNWKQL4cjs.toPosixPath.call(void 0, appDir)}/api/`)
3825
3937
  )) {
3826
3938
  for (const mod of modules) server2.moduleGraph.invalidateModule(mod);
3827
- await _optionalChain([refreshRouteDiscovery, 'optionalCall', _369 => _369(`updated ${file}`)]);
3939
+ await _optionalChain([refreshRouteDiscovery, 'optionalCall', _385 => _385(`updated ${file}`)]);
3828
3940
  server2.ws.send({ type: "full-reload", path: "*" });
3829
3941
  return [];
3830
3942
  }
3831
- const currentSrcRoot = currentFarmConfig ? _chunk5Y2P454Ocjs.getFarmSourceRoots.call(void 0, currentFarmConfig).map((source) => path5.join(source.root, source.srcDir).replace(/\\/g, "/")).find((sourceRoot) => normalizedFile.startsWith(`${sourceRoot}/`)) || null : null;
3943
+ const currentSrcRoot = currentFarmConfig ? _chunk5Y2P454Ocjs.getFarmSourceRoots.call(void 0, currentFarmConfig).map((source) => path6.join(source.root, source.srcDir).replace(/\\/g, "/")).find((sourceRoot) => normalizedFile.startsWith(`${sourceRoot}/`)) || null : null;
3832
3944
  if (currentSrcRoot && normalizedFile.startsWith(`${currentSrcRoot}/`) && _chunkE7QOEV5Zcjs.isProgrammaticRoutesFileName.call(void 0, normalizedFile)) {
3833
- logUpdate("PAGE", `updated ${path5.basename(file)}`);
3945
+ logUpdate("PAGE", `updated ${path6.basename(file)}`);
3834
3946
  for (const mod of modules) {
3835
3947
  server2.moduleGraph.invalidateModule(mod);
3836
3948
  }
3837
- await _optionalChain([refreshRouteDiscovery, 'optionalCall', _370 => _370(`updated ${file}`)]);
3949
+ await _optionalChain([refreshRouteDiscovery, 'optionalCall', _386 => _386(`updated ${file}`)]);
3838
3950
  server2.ws.send({
3839
3951
  type: "full-reload",
3840
3952
  path: "*"
@@ -3847,7 +3959,7 @@ if (import.meta.hot) {
3847
3959
  for (const mod of modules) {
3848
3960
  server2.moduleGraph.invalidateModule(mod);
3849
3961
  }
3850
- await _optionalChain([refreshRouteDiscovery, 'optionalCall', _371 => _371(`updated ${file}`)]);
3962
+ await _optionalChain([refreshRouteDiscovery, 'optionalCall', _387 => _387(`updated ${file}`)]);
3851
3963
  server2.ws.send({
3852
3964
  type: "full-reload",
3853
3965
  path: "*"
@@ -3855,12 +3967,12 @@ if (import.meta.hot) {
3855
3967
  return [];
3856
3968
  }
3857
3969
  if (apiRouteManager && _chunkJYNNIGQOcjs.invalidateFarmDevDependents.call(void 0, server2, file, apiRouteManager.getSourceFiles()).length > 0) {
3858
- await _optionalChain([refreshRouteDiscovery, 'optionalCall', _372 => _372(`updated ${file}`)]);
3970
+ await _optionalChain([refreshRouteDiscovery, 'optionalCall', _388 => _388(`updated ${file}`)]);
3859
3971
  }
3860
- const isolatedHydrationMode = _optionalChain([currentFarmConfig, 'optionalAccess', _373 => _373.experimental, 'optionalAccess', _374 => _374.isolatedClientHydration]);
3861
- const planRouteManager = _optionalChain([farmApp, 'optionalAccess', _375 => _375.getRouteManager, 'call', _376 => _376()]);
3972
+ const isolatedHydrationMode = _optionalChain([currentFarmConfig, 'optionalAccess', _389 => _389.experimental, 'optionalAccess', _390 => _390.isolatedClientHydration]);
3973
+ const planRouteManager = _optionalChain([farmApp, 'optionalAccess', _391 => _391.getRouteManager, 'call', _392 => _392()]);
3862
3974
  const isHydrationPlanSource = currentSrcRoot !== null && normalizedFile.startsWith(`${currentSrcRoot}/`) && /\.[cm]?[jt]sx?$/.test(normalizedFile);
3863
- const tracksAsyncOwnerIslands = _chunkRD623KW4cjs.isReactRenderer.call(void 0, _optionalChain([currentFarmConfig, 'optionalAccess', _377 => _377.renderer])) && planRouteManager !== void 0;
3975
+ const tracksAsyncOwnerIslands = _chunkRD623KW4cjs.isReactRenderer.call(void 0, _optionalChain([currentFarmConfig, 'optionalAccess', _393 => _393.renderer])) && planRouteManager !== void 0;
3864
3976
  if (isHydrationPlanSource && (isolatedHydrationMode === "enabled" || isolatedHydrationMode === "analyze" || tracksAsyncOwnerIslands)) {
3865
3977
  const routeManager = planRouteManager;
3866
3978
  if (routeManager) {
@@ -3920,7 +4032,7 @@ if (import.meta.hot) {
3920
4032
  }
3921
4033
  return [];
3922
4034
  }
3923
- _optionalChain([farmApp, 'optionalAccess', _378 => _378.getRouteManager, 'call', _379 => _379(), 'access', _380 => _380.invalidateClientManifest, 'call', _381 => _381()]);
4035
+ _optionalChain([farmApp, 'optionalAccess', _394 => _394.getRouteManager, 'call', _395 => _395(), 'access', _396 => _396.invalidateClientManifest, 'call', _397 => _397()]);
3924
4036
  const manifestModule = server2.moduleGraph.getModuleById("/@farm/manifest");
3925
4037
  if (manifestModule) {
3926
4038
  server2.moduleGraph.invalidateModule(manifestModule);
@@ -3961,21 +4073,21 @@ function createPageDataMiddlewareRequest(req, target) {
3961
4073
  }
3962
4074
  function resolveDevelopmentRoot(farmRoot, viteRoot) {
3963
4075
  if (!farmRoot) return viteRoot;
3964
- if (path5.resolve(farmRoot) === path5.resolve(viteRoot)) return farmRoot;
4076
+ if (path6.resolve(farmRoot) === path6.resolve(viteRoot)) return farmRoot;
3965
4077
  try {
3966
4078
  if (fs2.realpathSync(farmRoot) === fs2.realpathSync(viteRoot)) {
3967
- return path5.resolve(viteRoot);
4079
+ return path6.resolve(viteRoot);
3968
4080
  }
3969
- } catch (e14) {
4081
+ } catch (e16) {
3970
4082
  }
3971
4083
  return farmRoot;
3972
4084
  }
3973
4085
  var farmIslandInferenceDependents = /* @__PURE__ */ new Map();
3974
4086
  function recordFarmIslandInferenceDependency(file, island) {
3975
- const key = path5.resolve(file);
4087
+ const key = path6.resolve(file);
3976
4088
  let islands = farmIslandInferenceDependents.get(key);
3977
4089
  if (!islands) farmIslandInferenceDependents.set(key, islands = /* @__PURE__ */ new Set());
3978
- islands.add(path5.resolve(island));
4090
+ islands.add(path6.resolve(island));
3979
4091
  }
3980
4092
  var FARM_DEV_CLIENT_BOOT_ID = "/@farm/client-boot.js";
3981
4093
  var FARM_DEV_CLIENT_BOOT_MODULE = 'import { startFarmIslandsBoot } from "@farm.js/core/internal/islands-boot";\nstartFarmIslandsBoot();\n';
@@ -3985,12 +4097,12 @@ function isFarmClientVirtualId(id) {
3985
4097
  }
3986
4098
  function isClientEnvironment(context, loadOptions) {
3987
4099
  const environment = context.environment;
3988
- if (_optionalChain([environment, 'optionalAccess', _382 => _382.config, 'optionalAccess', _383 => _383.consumer])) return environment.config.consumer === "client";
3989
- if (_optionalChain([environment, 'optionalAccess', _384 => _384.name])) return environment.name === "client";
3990
- return _optionalChain([loadOptions, 'optionalAccess', _385 => _385.ssr]) !== true;
4100
+ if (_optionalChain([environment, 'optionalAccess', _398 => _398.config, 'optionalAccess', _399 => _399.consumer])) return environment.config.consumer === "client";
4101
+ if (_optionalChain([environment, 'optionalAccess', _400 => _400.name])) return environment.name === "client";
4102
+ return _optionalChain([loadOptions, 'optionalAccess', _401 => _401.ssr]) !== true;
3991
4103
  }
3992
4104
  function invalidateProgrammaticClientRouteModules(server) {
3993
- const graph = _optionalChain([server, 'access', _386 => _386.environments, 'optionalAccess', _387 => _387.client, 'optionalAccess', _388 => _388.moduleGraph]);
4105
+ const graph = _optionalChain([server, 'access', _402 => _402.environments, 'optionalAccess', _403 => _403.client, 'optionalAccess', _404 => _404.moduleGraph]);
3994
4106
  if (!graph) return;
3995
4107
  for (const [id, module] of graph.idToModuleMap) {
3996
4108
  if (_chunkE7QOEV5Zcjs.parseProgrammaticRouteModuleId.call(void 0, id)) graph.invalidateModule(module);
@@ -4004,7 +4116,7 @@ function generateProgrammaticClientRouteModuleForId(moduleId, root, renderer, cl
4004
4116
  kind: parsed.kind,
4005
4117
  routePath: parsed.routePath,
4006
4118
  routesFile,
4007
- route: parsed.kind === "api" ? void 0 : _optionalChain([clientRoutes, 'optionalAccess', _389 => _389.routes, 'access', _390 => _390.get, 'call', _391 => _391(
4119
+ route: parsed.kind === "api" ? void 0 : _optionalChain([clientRoutes, 'optionalAccess', _405 => _405.routes, 'access', _406 => _406.get, 'call', _407 => _407(
4008
4120
  _chunkNK2VWS7Pcjs.programmaticClientRouteKey.call(void 0, routesFile, parsed.kind, parsed.routePath)
4009
4121
  )]),
4010
4122
  rendererServer: renderer.server,
@@ -4012,10 +4124,10 @@ function generateProgrammaticClientRouteModuleForId(moduleId, root, renderer, cl
4012
4124
  });
4013
4125
  }
4014
4126
  function resolveRealModuleFile(filePath, root) {
4015
- const resolved = _nullishCoalesce(_chunkUYSTTPYJcjs.resolveModuleSourcePath.call(void 0, filePath, root), () => ( filePath));
4127
+ const resolved = _nullishCoalesce(_chunkGGNJAGGEcjs.resolveModuleSourcePath.call(void 0, filePath, root), () => ( filePath));
4016
4128
  try {
4017
4129
  return _chunkQMNWKQL4cjs.toPosixPath.call(void 0, fs2.realpathSync(resolved));
4018
- } catch (e15) {
4130
+ } catch (e17) {
4019
4131
  return _chunkQMNWKQL4cjs.toPosixPath.call(void 0, resolved);
4020
4132
  }
4021
4133
  }
@@ -4326,12 +4438,12 @@ async function parseRouteModuleProps(routeModule, input) {
4326
4438
  }
4327
4439
  const schemas = routeModule.__farmRouteSchemas;
4328
4440
  const params = parseRouteModuleSchema(
4329
- _optionalChain([schemas, 'optionalAccess', _392 => _392.params]),
4441
+ _optionalChain([schemas, 'optionalAccess', _408 => _408.params]),
4330
4442
  input.props.params,
4331
4443
  "params",
4332
4444
  input.routePath
4333
4445
  );
4334
- const search = parseRouteModuleSchema(_optionalChain([schemas, 'optionalAccess', _393 => _393.search]), input.search, "search", input.routePath);
4446
+ const search = parseRouteModuleSchema(_optionalChain([schemas, 'optionalAccess', _409 => _409.search]), input.search, "search", input.routePath);
4335
4447
  return {
4336
4448
  ...input.props,
4337
4449
  params,
@@ -4351,12 +4463,12 @@ function parseRouteModuleSchema(schema, value, label, routePath) {
4351
4463
  }
4352
4464
  }
4353
4465
  function generateClientCode(integrationProviders = [], documentNavigationMatchers = [], docsSearchClientRuntime = EMPTY_FARM_DOCS_SEARCH_CLIENT_RUNTIME, devtoolsClientRuntime = "", plugins = [], root = process.cwd(), srcDir = "src", publicRuntimeConfig = void 0, docsAdapterReact, renderer = _chunkRD623KW4cjs.REACT_RENDERER, isolatedHydrationEnabled = false, trailingSlash = false, basePath = "/", clientCachePersistence = { imports: "", init: "" }, docsConfigModule, islandValues = false) {
4354
- const providerClientCode = _chunkUYSTTPYJcjs.generateFarmIntegrationProviderClientCode.call(void 0,
4466
+ const providerClientCode = _chunkGGNJAGGEcjs.generateFarmIntegrationProviderClientCode.call(void 0,
4355
4467
  integrationProviders,
4356
4468
  root,
4357
4469
  _nullishCoalesce(renderer.componentExtensions, () => ( []))
4358
4470
  );
4359
- const clientPluginEntry = _chunkUYSTTPYJcjs.generateFarmClientPluginEntryCode.call(void 0,
4471
+ const clientPluginEntry = _chunkGGNJAGGEcjs.generateFarmClientPluginEntryCode.call(void 0,
4360
4472
  plugins,
4361
4473
  root,
4362
4474
  srcDir,
@@ -4404,7 +4516,7 @@ async function createFarmServerTreePageElement(source, pathname) {
4404
4516
  return null;
4405
4517
  }
4406
4518
  }
4407
- ${islandValues ? `${_chunkUYSTTPYJcjs.FARM_SERVER_TREE_LAYOUT_CLIENT_SOURCE}
4519
+ ${islandValues ? `${_chunkGGNJAGGEcjs.FARM_SERVER_TREE_LAYOUT_CLIENT_SOURCE}
4408
4520
  let farmLastRouteState = null;
4409
4521
 
4410
4522
  // A hot update to a layout tree's client module renders the route again.
@@ -5215,7 +5327,7 @@ async function loadLayoutComponents(layouts = [], params = {}, source) {
5215
5327
  return loadedLayouts;
5216
5328
  }
5217
5329
 
5218
- ${_chunkUYSTTPYJcjs.FARM_LAYOUT_ELEMENT_CLIENT_SOURCE}
5330
+ ${_chunkGGNJAGGEcjs.FARM_LAYOUT_ELEMENT_CLIENT_SOURCE}
5219
5331
  function wrapWithLoadedLayouts(element, loadedLayouts, params) {
5220
5332
  let wrapped = element;
5221
5333
  for (let index = loadedLayouts.length - 1; index >= 0; index--) {
@@ -5572,7 +5684,7 @@ function replaceNavigationBoundary(
5572
5684
  return nextTarget;
5573
5685
  }
5574
5686
 
5575
- ${islandValues ? `${_chunkUYSTTPYJcjs.FARM_NAVIGATION_STREAM_READER_SOURCE}
5687
+ ${islandValues ? `${_chunkGGNJAGGEcjs.FARM_NAVIGATION_STREAM_READER_SOURCE}
5576
5688
 
5577
5689
  // Islands mode navigates as the production client does: it fetches the page itself, names the
5578
5690
  // layouts it shows by key (F-Layouts), and asks for flush markers (F-Stream), so the shell arrives
@@ -6255,8 +6367,8 @@ function generateClientManifest(bundle) {
6255
6367
  }
6256
6368
  async function defineConfig(config = {}) {
6257
6369
  const tailwindVitePlugin = await _chunkR53QDV6Tcjs.loadTailwindVitePlugin.call(void 0, );
6258
- const appRoot = path5.resolve(config.root || process.cwd());
6259
- if (_optionalChain([config, 'access', _394 => _394.extends, 'optionalAccess', _395 => _395.length])) {
6370
+ const appRoot = path6.resolve(config.root || process.cwd());
6371
+ if (_optionalChain([config, 'access', _410 => _410.extends, 'optionalAccess', _411 => _411.length])) {
6260
6372
  const { config: layeredConfig } = await import("./layers-DMRXRL7F.cjs").then(
6261
6373
  ({ resolveFarmLayers }) => resolveFarmLayers(config, {
6262
6374
  root: appRoot,
@@ -6266,7 +6378,7 @@ async function defineConfig(config = {}) {
6266
6378
  config = layeredConfig;
6267
6379
  }
6268
6380
  config.renderer = _chunkRD623KW4cjs.resolveFarmRenderer.call(void 0, config.renderer);
6269
- config.images = _chunkUYSTTPYJcjs.resolveFarmImageProviderForRuntime.call(void 0, config.images, { root: appRoot, dev: true });
6381
+ config.images = _chunkGGNJAGGEcjs.resolveFarmImageProviderForRuntime.call(void 0, config.images, { root: appRoot, dev: true });
6270
6382
  const rendererVitePlugins = await _chunkRD623KW4cjs.loadFarmRendererVitePlugins.call(void 0, config.renderer, appRoot, {
6271
6383
  ssr: true
6272
6384
  });
@@ -6358,13 +6470,13 @@ async function defineConfig(config = {}) {
6358
6470
  if (!serverStarted) {
6359
6471
  serverStarted = true;
6360
6472
  const elapsed = Date.now() - startTime;
6361
- const address = _optionalChain([server, 'access', _396 => _396.httpServer, 'optionalAccess', _397 => _397.address, 'call', _398 => _398()]);
6473
+ const address = _optionalChain([server, 'access', _412 => _412.httpServer, 'optionalAccess', _413 => _413.address, 'call', _414 => _414()]);
6362
6474
  const resolvedPort = typeof address === "object" && address ? address.port : server.config.server.port || port || 3e3;
6363
6475
  const hostConfig = server.config.server.host;
6364
6476
  const isExposed = hostConfig === true || hostConfig === "0.0.0.0";
6365
6477
  console.log("");
6366
6478
  console.log(
6367
- ` ${pc.bold(pc.green("Farm.js"))} ${pc.dim(`v${_chunk2FRLSDBTcjs.FARM_VERSION}`)} ${pc.dim(`ready in ${elapsed}ms`)}`
6479
+ ` ${pc.bold(pc.green("Farm.js"))} ${pc.dim(`v${_chunkSM25ZC4Scjs.FARM_VERSION}`)} ${pc.dim(`ready in ${elapsed}ms`)}`
6368
6480
  );
6369
6481
  console.log("");
6370
6482
  console.log(
@@ -6398,7 +6510,7 @@ async function defineConfig(config = {}) {
6398
6510
  plugins: [
6399
6511
  // `farm dev --desktop`: only the desktop window gets an answer, as in the packaged app.
6400
6512
  _chunk65Y5SIBHcjs.farmDesktopDevGuardPlugin.call(void 0, config.basePath),
6401
- _chunkUYSTTPYJcjs.createFarmThemeCssPlugin.call(void 0, config.theme, config.basePath),
6513
+ _chunkGGNJAGGEcjs.createFarmThemeCssPlugin.call(void 0, config.theme, config.basePath),
6402
6514
  tailwindVitePlugin,
6403
6515
  ...rendererVitePlugins,
6404
6516
  ...reactRefreshPlugins,
@@ -6412,8 +6524,8 @@ async function defineConfig(config = {}) {
6412
6524
  customLogger: farmLogger,
6413
6525
  clearScreen: false,
6414
6526
  optimizeDeps: {
6415
- ..._chunkUYSTTPYJcjs.createFarmClientOptimizeDepsConfig.call(void 0,
6416
- _chunkUYSTTPYJcjs.createFarmClientOptimizeDepsEntries.call(void 0,
6527
+ ..._chunkGGNJAGGEcjs.createFarmClientOptimizeDepsConfig.call(void 0,
6528
+ _chunkGGNJAGGEcjs.createFarmClientOptimizeDepsEntries.call(void 0,
6417
6529
  appRoot,
6418
6530
  _chunk5Y2P454Ocjs.getFarmAppDirectories.call(void 0, { ...config, root: appRoot })
6419
6531
  ),
@@ -6456,7 +6568,7 @@ async function defineConfig(config = {}) {
6456
6568
  // Stub out problematic server-only modules during dev mode
6457
6569
  alias: {
6458
6570
  ..._chunk5Y2P454Ocjs.getFarmLayerAliases.call(void 0, config.layers),
6459
- ..._chunkUYSTTPYJcjs.createFarmSourceAlias.call(void 0, appRoot, config.srcDir),
6571
+ ..._chunkGGNJAGGEcjs.createFarmSourceAlias.call(void 0, appRoot, config.srcDir),
6460
6572
  // Nitro internals that should not be resolved in browser
6461
6573
  "supports-color": "data:text/javascript,export default false; export const supportsColor = false; export const stdout = false; export const stderr = false;",
6462
6574
  "@poppinss/dumper": "data:text/javascript,export default {};",