@farm.js/core 0.1.86 → 0.1.87

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 (232) hide show
  1. package/dist/{agent-mcp.d-7uKdOttc.d.ts → agent-mcp.d-BdM0pIrD.d.ts} +1 -1
  2. package/dist/{agent-mcp.d-LChlR2au.d.mts → agent-mcp.d-CMGqpUbk.d.mts} +1 -1
  3. package/dist/agent-runtime.d.mts +1 -1
  4. package/dist/agent-runtime.d.ts +1 -1
  5. package/dist/analyzer-LLU2Z6I4.cjs +17 -0
  6. package/dist/{analyzer-I5S5YKHM.mjs → analyzer-W4EB7DHL.mjs} +2 -2
  7. package/dist/api/node.d.mts +3 -3
  8. package/dist/api/node.d.ts +3 -3
  9. package/dist/api/route-manager.cjs +3 -3
  10. package/dist/api/route-manager.d.mts +3 -3
  11. package/dist/api/route-manager.d.ts +3 -3
  12. package/dist/api/route-manager.mjs +2 -2
  13. package/dist/api/runtime.d.mts +2 -2
  14. package/dist/api/runtime.d.ts +2 -2
  15. package/dist/api.cjs +4 -4
  16. package/dist/api.d.mts +4 -4
  17. package/dist/api.d.ts +4 -4
  18. package/dist/api.mjs +3 -3
  19. package/dist/{app-manifest.d-QMdmqqCr.d.mts → app-manifest.d-BeDB2OVm.d.mts} +1 -1
  20. package/dist/{app-manifest.d-CRp21oAz.d.ts → app-manifest.d-COhjPgHn.d.ts} +1 -1
  21. package/dist/app-markdown.d.mts +2 -2
  22. package/dist/app-markdown.d.ts +2 -2
  23. package/dist/{app.d-Bvpc2eJq.d.mts → app.d-AVZXCfcO.d.mts} +5 -4
  24. package/dist/{app.d-DEKpJEp4.d.ts → app.d-b3A4cca5.d.ts} +5 -4
  25. package/dist/{chunk-SB74WCKC.mjs → chunk-26HESRBL.mjs} +4 -4
  26. package/dist/chunk-2HTNASSB.cjs +134 -0
  27. package/dist/{chunk-BAD6T5NU.cjs → chunk-33WR5XV5.cjs} +4 -4
  28. package/dist/{chunk-YMAE32O7.mjs → chunk-3F55K4MC.mjs} +1 -1
  29. package/dist/{chunk-CVKTYG4L.mjs → chunk-4FGTNYHE.mjs} +2 -2
  30. package/dist/{chunk-CFKAYV7B.mjs → chunk-5D73SKF3.mjs} +1 -1
  31. package/dist/{chunk-Q3YWQEUS.cjs → chunk-7BNVUIGL.cjs} +2 -2
  32. package/dist/{chunk-RA5OUXOJ.mjs → chunk-A2PPQ5LB.mjs} +2 -2
  33. package/dist/{chunk-KHIEGVG7.mjs → chunk-ALOFMAFA.mjs} +10 -4
  34. package/dist/{chunk-BLZCAFGJ.cjs → chunk-CXHVRHM2.cjs} +2 -2
  35. package/dist/{chunk-3RVLJTFZ.mjs → chunk-D7LXBLUW.mjs} +1 -1
  36. package/dist/{chunk-45ANSCTO.mjs → chunk-EZYNIADW.mjs} +63 -37
  37. package/dist/{chunk-NAHDG6UX.mjs → chunk-HFRG2IQS.mjs} +1 -1
  38. package/dist/{chunk-7H2TXT2K.mjs → chunk-HX5HLFBZ.mjs} +7 -0
  39. package/dist/{chunk-2NKNP4AH.cjs → chunk-HYL372GW.cjs} +1 -1
  40. package/dist/{chunk-25JGHAGH.cjs → chunk-I2RBHZF7.cjs} +15 -8
  41. package/dist/{chunk-NXOZRI3B.cjs → chunk-IM422XKU.cjs} +2 -2
  42. package/dist/{chunk-6QYPP5KC.mjs → chunk-K5FLQJW5.mjs} +2 -2
  43. package/dist/chunk-K6RMOB25.mjs +134 -0
  44. package/dist/{chunk-UAQQUQWE.mjs → chunk-LBJOHMTB.mjs} +1 -1
  45. package/dist/{chunk-QYWP5KDY.mjs → chunk-LIWVPE72.mjs} +59 -21
  46. package/dist/{chunk-FDU4Q4QP.cjs → chunk-MZR22RAC.cjs} +10 -4
  47. package/dist/chunk-NDMPGFKL.cjs +47 -0
  48. package/dist/{chunk-YHM4PXJY.mjs → chunk-O5YM6GU3.mjs} +1 -1
  49. package/dist/{chunk-GWPANDW3.mjs → chunk-O7K4HMAQ.mjs} +1 -1
  50. package/dist/{chunk-7UTRNV6R.mjs → chunk-Q73LRKLP.mjs} +1 -1
  51. package/dist/{chunk-3TKGMIPX.mjs → chunk-QLRI2BX5.mjs} +90 -11
  52. package/dist/{chunk-PAENAKTC.mjs → chunk-QSDIJ45N.mjs} +1 -1
  53. package/dist/{chunk-UDWBTABT.cjs → chunk-RGYS5OPL.cjs} +3 -3
  54. package/dist/{chunk-FWLXYNWA.cjs → chunk-SDNYULFS.cjs} +347 -321
  55. package/dist/chunk-TCGPBSVY.mjs +47 -0
  56. package/dist/{chunk-P253SZJF.cjs → chunk-TI4BZV6M.cjs} +353 -274
  57. package/dist/{chunk-QYDGIXQ5.cjs → chunk-U3A46QFD.cjs} +9 -9
  58. package/dist/{chunk-VGHDPEPQ.cjs → chunk-UA77C2ZA.cjs} +2 -2
  59. package/dist/{chunk-U54REWMJ.cjs → chunk-VCI776NG.cjs} +13 -13
  60. package/dist/{chunk-IAERD73G.cjs → chunk-VCZ4EM5K.cjs} +367 -329
  61. package/dist/{chunk-5P65LXGU.cjs → chunk-WSQ3S3NV.cjs} +2 -2
  62. package/dist/{chunk-VTEAUQMT.mjs → chunk-X2SMVPLH.mjs} +19 -3
  63. package/dist/{chunk-TQJ35BBW.cjs → chunk-XFUPWRKT.cjs} +4 -4
  64. package/dist/{chunk-DJ3PVHTW.cjs → chunk-XGPRM7OK.cjs} +3 -3
  65. package/dist/{chunk-CPSFDQKJ.cjs → chunk-Z43CIBUR.cjs} +20 -4
  66. package/dist/{chunk-L2IULWKV.cjs → chunk-ZCX2XJPY.cjs} +3 -3
  67. package/dist/{cli-runtime.d-DaElKjaL.d.ts → cli-runtime.d-jqZ7YCsm.d.ts} +5 -5
  68. package/dist/{cli-runtime.d-C7aMfoTq.d.mts → cli-runtime.d-qL44rqYO.d.mts} +5 -5
  69. package/dist/{client-component.d-miqIXyQv.d.mts → client-component.d-B2L2LyAr.d.mts} +1 -1
  70. package/dist/{client-component.d-CZG02pIh.d.ts → client-component.d-BDD5aiUb.d.ts} +1 -1
  71. package/dist/{client-plugins.d-BVXjyIkY.d.ts → client-plugins.d-Crct3m_r.d.ts} +14 -5
  72. package/dist/{client-plugins.d-BwKwuO_0.d.mts → client-plugins.d-Dzc3vOw_.d.mts} +14 -5
  73. package/dist/client-plugins.d.mts +1 -1
  74. package/dist/client-plugins.d.ts +1 -1
  75. package/dist/client.d.mts +8 -7
  76. package/dist/client.d.ts +8 -7
  77. package/dist/config.d.mts +1 -1
  78. package/dist/config.d.ts +1 -1
  79. package/dist/desktop.d.mts +2 -2
  80. package/dist/desktop.d.ts +2 -2
  81. package/dist/{devtools-A3L7WNTB.cjs → devtools-GPIKZ5AV.cjs} +5 -3
  82. package/dist/{devtools-DGC2247E.mjs → devtools-GWJZPWIW.mjs} +4 -2
  83. package/dist/docs.cjs +6 -4
  84. package/dist/docs.d.mts +3 -3
  85. package/dist/docs.d.ts +3 -3
  86. package/dist/docs.mjs +5 -3
  87. package/dist/environment/vite.cjs +4 -4
  88. package/dist/environment/vite.mjs +3 -3
  89. package/dist/font.cjs +4 -2
  90. package/dist/font.d.mts +13 -1
  91. package/dist/font.d.ts +13 -1
  92. package/dist/font.mjs +3 -1
  93. package/dist/{handler.d-BKTWzzNA.d.mts → handler.d-B1S1ZBqS.d.mts} +1 -1
  94. package/dist/{handler.d-Dzpyg3-N.d.ts → handler.d-ZweCBJD4.d.ts} +1 -1
  95. package/dist/{headers.d-PZyXcDAH.d.ts → headers.d-BgBdQN8x.d.ts} +1 -1
  96. package/dist/{headers.d-5opjyhXw.d.mts → headers.d-C-yGl_f6.d.mts} +1 -1
  97. package/dist/image-attributes.d-BMPDQO1q.d.mts +55 -0
  98. package/dist/image-attributes.d-BMPDQO1q.d.ts +55 -0
  99. package/dist/image.cjs +5 -127
  100. package/dist/image.d.mts +3 -13
  101. package/dist/image.d.ts +3 -13
  102. package/dist/image.mjs +5 -127
  103. package/dist/index.cjs +24 -22
  104. package/dist/{index.d-C0Mie66f.d.mts → index.d-13h3oDu7.d.mts} +1 -1
  105. package/dist/{index.d-DV2q-0mE.d.ts → index.d-CtoniAXT.d.ts} +1 -1
  106. package/dist/index.d.mts +24 -23
  107. package/dist/index.d.ts +24 -23
  108. package/dist/index.mjs +23 -21
  109. package/dist/integrations/orm.d.mts +1 -1
  110. package/dist/integrations/orm.d.ts +1 -1
  111. package/dist/integrations.d.mts +1 -1
  112. package/dist/integrations.d.ts +1 -1
  113. package/dist/internal/app-markdown-runtime.d.mts +2 -2
  114. package/dist/internal/app-markdown-runtime.d.ts +2 -2
  115. package/dist/internal/build-runtime.cjs +19 -19
  116. package/dist/internal/build-runtime.d.mts +4 -4
  117. package/dist/internal/build-runtime.d.ts +4 -4
  118. package/dist/internal/build-runtime.mjs +18 -18
  119. package/dist/internal/cli-runtime.cjs +5 -3
  120. package/dist/internal/cli-runtime.d.mts +7 -7
  121. package/dist/internal/cli-runtime.d.ts +7 -7
  122. package/dist/internal/cli-runtime.mjs +4 -2
  123. package/dist/internal/client-error-overlay.cjs +4 -4
  124. package/dist/internal/client-error-overlay.mjs +1 -1
  125. package/dist/internal/client-runtime.cjs +66 -40
  126. package/dist/internal/client-runtime.d.mts +6 -6
  127. package/dist/internal/client-runtime.d.ts +6 -6
  128. package/dist/internal/client-runtime.mjs +53 -27
  129. package/dist/internal/compression-runtime.d.mts +1 -1
  130. package/dist/internal/compression-runtime.d.ts +1 -1
  131. package/dist/internal/config-runtime.cjs +6 -4
  132. package/dist/internal/config-runtime.d.mts +3 -3
  133. package/dist/internal/config-runtime.d.ts +3 -3
  134. package/dist/internal/config-runtime.mjs +5 -3
  135. package/dist/internal/infra-analytics-runtime.cjs +6 -6
  136. package/dist/internal/infra-analytics-runtime.mjs +4 -4
  137. package/dist/internal/islands-boot.cjs +44 -16
  138. package/dist/internal/islands-boot.d.mts +3 -1
  139. package/dist/internal/islands-boot.d.ts +3 -1
  140. package/dist/internal/islands-boot.mjs +28 -0
  141. package/dist/internal/native-server-fns.cjs +4 -4
  142. package/dist/internal/native-server-fns.mjs +3 -3
  143. package/dist/internal/product-telemetry-runtime.cjs +3 -3
  144. package/dist/internal/product-telemetry-runtime.mjs +2 -2
  145. package/dist/internal/production-runtime.cjs +6 -6
  146. package/dist/internal/production-runtime.d.mts +10 -10
  147. package/dist/internal/production-runtime.d.ts +10 -10
  148. package/dist/internal/production-runtime.mjs +5 -5
  149. package/dist/internal/renderer-islands.cjs +35 -8
  150. package/dist/internal/renderer-islands.d.mts +9 -1
  151. package/dist/internal/renderer-islands.d.ts +9 -1
  152. package/dist/internal/renderer-islands.mjs +35 -8
  153. package/dist/internal/spa-router.d.mts +3 -3
  154. package/dist/internal/spa-router.d.ts +3 -3
  155. package/dist/internal/start-manifest.d.mts +1 -1
  156. package/dist/internal/start-manifest.d.ts +1 -1
  157. package/dist/{island-runtime.d-BA7EPo1v.d.ts → island-runtime.d-D2Mh5eTU.d.ts} +5 -1
  158. package/dist/{island-runtime.d-BBS_YUSX.d.mts → island-runtime.d-lrpEJlgg.d.mts} +5 -1
  159. package/dist/markdown.d.mts +1 -1
  160. package/dist/markdown.d.ts +1 -1
  161. package/dist/middleware.cjs +4 -4
  162. package/dist/middleware.d.mts +1 -1
  163. package/dist/middleware.d.ts +1 -1
  164. package/dist/middleware.mjs +3 -3
  165. package/dist/{mount.d-gWul1GA1.d.ts → mount.d-DyKlRR6z.d.ts} +1 -1
  166. package/dist/{mount.d-CZ_qL1iS.d.mts → mount.d-_6Un9wdK.d.mts} +1 -1
  167. package/dist/{navigation-delegate.d-BBTzhJLj.d.mts → navigation-delegate.d-ChfinbWB.d.mts} +1 -1
  168. package/dist/{navigation-delegate.d-BZsYEAet.d.ts → navigation-delegate.d-fMgELdAe.d.ts} +1 -1
  169. package/dist/navigation.d.mts +4 -4
  170. package/dist/navigation.d.ts +4 -4
  171. package/dist/{plugin-QOTAPTVV.mjs → plugin-EVKQZBNW.mjs} +1 -1
  172. package/dist/{plugin-3PT7I26P.cjs → plugin-MWO3G2XM.cjs} +2 -2
  173. package/dist/plugin.cjs +16 -16
  174. package/dist/plugin.d.mts +5 -5
  175. package/dist/plugin.d.ts +5 -5
  176. package/dist/plugin.mjs +15 -15
  177. package/dist/{render-plan.d-AaJsYPX-.d.ts → render-plan.d-D0FV9lDT.d.ts} +1 -1
  178. package/dist/{render-plan.d-bnWxS12w.d.mts → render-plan.d-DaM1NPnm.d.mts} +1 -1
  179. package/dist/renderer-client.cjs +6 -1
  180. package/dist/renderer-client.d.mts +6 -5
  181. package/dist/renderer-client.d.ts +6 -5
  182. package/dist/renderer-client.mjs +5 -0
  183. package/dist/renderer.cjs +3 -3
  184. package/dist/renderer.mjs +2 -2
  185. package/dist/{request.d-CAeitOG1.d.ts → request.d-CrXC7voZ.d.ts} +1 -1
  186. package/dist/{request.d-C2HOn3Hi.d.mts → request.d-DVSLilGx.d.mts} +1 -1
  187. package/dist/request.d.mts +2 -2
  188. package/dist/request.d.ts +2 -2
  189. package/dist/{route-rendering.d-CYA-ulnX.d.mts → route-rendering.d-CWi3UYtR.d.mts} +1 -1
  190. package/dist/{route-rendering.d-A1dIkUK5.d.ts → route-rendering.d-OfbM_rj8.d.ts} +1 -1
  191. package/dist/{router.d-A_Yt6jYz.d.ts → router.d-D5Mp7bpO.d.ts} +1 -1
  192. package/dist/{router.d-8lxnzlkr.d.mts → router.d-DrQ1QDFk.d.mts} +1 -1
  193. package/dist/routes.d.mts +1 -1
  194. package/dist/routes.d.ts +1 -1
  195. package/dist/{rsc-pipeline-BROS3NEB.mjs → rsc-pipeline-KLMQU3YP.mjs} +5 -3
  196. package/dist/{rsc-pipeline-SNGPAXGW.cjs → rsc-pipeline-TQOSDWOU.cjs} +6 -4
  197. package/dist/{runtime-SLJLW37A.mjs → runtime-BDPBO65S.mjs} +5 -3
  198. package/dist/{runtime-7T5TRAWL.cjs → runtime-CQSCRVZ7.cjs} +7 -5
  199. package/dist/{runtime.d-C_rZ9_DD.d.mts → runtime.d-BVj6apd0.d.mts} +1 -1
  200. package/dist/{runtime.d-BPyvWrgQ.d.ts → runtime.d-D7QYVJGO.d.ts} +1 -1
  201. package/dist/{server-components-status.d-BpxiEMQE.d.mts → server-components-status.d-BDVcxi0z.d.mts} +1 -1
  202. package/dist/{server-components-status.d-C2UEKJn7.d.ts → server-components-status.d-CfKDpmCH.d.ts} +1 -1
  203. package/dist/server-plugins.d.mts +3 -3
  204. package/dist/server-plugins.d.ts +3 -3
  205. package/dist/server.cjs +37 -37
  206. package/dist/server.d.mts +11 -11
  207. package/dist/server.d.ts +11 -11
  208. package/dist/server.mjs +17 -17
  209. package/dist/{spa-router.d-Cw5i_15e.d.ts → spa-router.d-BXxoU3Cv.d.ts} +2 -2
  210. package/dist/{spa-router.d-BD-6WX1R.d.mts → spa-router.d-CXgvy-7L.d.mts} +2 -2
  211. package/dist/{ssg.d-CCE9aob5.d.mts → ssg.d-DS-gXUbf.d.mts} +2 -2
  212. package/dist/{ssg.d-Bifiq0EL.d.ts → ssg.d-jXlUAKzg.d.ts} +2 -2
  213. package/dist/{store-core.d-BN2MxSG9.d.mts → store-core.d-CDbVAbTn.d.mts} +3 -2
  214. package/dist/{store-core.d-5tVn5vi1.d.ts → store-core.d-D00BsbnO.d.ts} +3 -2
  215. package/dist/testing.cjs +2 -2
  216. package/dist/testing.d.mts +1 -1
  217. package/dist/testing.d.ts +1 -1
  218. package/dist/testing.mjs +2 -2
  219. package/dist/{utils.d-BUjpSNIO.d.ts → utils.d-BODwBtkz.d.ts} +1 -1
  220. package/dist/{utils.d-wGPLeVbq.d.mts → utils.d-Cmj-fzds.d.mts} +1 -1
  221. package/dist/version.cjs +2 -2
  222. package/dist/version.mjs +1 -1
  223. package/dist/vite.cjs +21 -19
  224. package/dist/vite.d.mts +21 -7
  225. package/dist/vite.d.ts +21 -7
  226. package/dist/vite.mjs +20 -18
  227. package/package.json +2 -2
  228. package/dist/analyzer-OEMQSLYT.cjs +0 -17
  229. package/dist/chunk-7EPYN7GW.cjs +0 -30
  230. package/dist/chunk-HZOMT5DY.mjs +0 -30
  231. package/dist/{chunk-4B6YJ5DS.cjs → chunk-4ZVKDHS6.cjs} +3 -3
  232. package/dist/{chunk-4EEAPBNV.mjs → chunk-PEQJ4UUT.mjs} +3 -3
@@ -32,7 +32,7 @@ var _chunkMHKPXX3Jcjs = require('./chunk-MHKPXX3J.cjs');
32
32
 
33
33
 
34
34
 
35
- var _chunkUDWBTABTcjs = require('./chunk-UDWBTABT.cjs');
35
+ var _chunkRGYS5OPLcjs = require('./chunk-RGYS5OPL.cjs');
36
36
 
37
37
 
38
38
 
@@ -40,7 +40,7 @@ var _chunkUDWBTABTcjs = require('./chunk-UDWBTABT.cjs');
40
40
 
41
41
 
42
42
 
43
- var _chunkBLZCAFGJcjs = require('./chunk-BLZCAFGJ.cjs');
43
+ var _chunkCXHVRHM2cjs = require('./chunk-CXHVRHM2.cjs');
44
44
 
45
45
 
46
46
 
@@ -70,7 +70,7 @@ var _chunkNDOE76QCcjs = require('./chunk-NDOE76QC.cjs');
70
70
 
71
71
 
72
72
 
73
- var _chunkFDU4Q4QPcjs = require('./chunk-FDU4Q4QP.cjs');
73
+ var _chunkMZR22RACcjs = require('./chunk-MZR22RAC.cjs');
74
74
 
75
75
 
76
76
  var _chunk3BTN3NP7cjs = require('./chunk-3BTN3NP7.cjs');
@@ -115,7 +115,8 @@ var _chunkO4JYMU5Ncjs = require('./chunk-O4JYMU5N.cjs');
115
115
 
116
116
 
117
117
 
118
- var _chunkP253SZJFcjs = require('./chunk-P253SZJF.cjs');
118
+
119
+ var _chunkTI4BZV6Mcjs = require('./chunk-TI4BZV6M.cjs');
119
120
 
120
121
 
121
122
 
@@ -134,11 +135,8 @@ var _chunkVACYUMXWcjs = require('./chunk-VACYUMXW.cjs');
134
135
  var _chunkXMVZXZ32cjs = require('./chunk-XMVZXZ32.cjs');
135
136
 
136
137
 
137
- var _chunkCPSFDQKJcjs = require('./chunk-CPSFDQKJ.cjs');
138
-
139
-
140
138
 
141
- var _chunkBAD6T5NUcjs = require('./chunk-BAD6T5NU.cjs');
139
+ var _chunk33WR5XV5cjs = require('./chunk-33WR5XV5.cjs');
142
140
 
143
141
 
144
142
 
@@ -151,7 +149,7 @@ var _chunkBAD6T5NUcjs = require('./chunk-BAD6T5NU.cjs');
151
149
 
152
150
 
153
151
 
154
- var _chunk4B6YJ5DScjs = require('./chunk-4B6YJ5DS.cjs');
152
+ var _chunk4ZVKDHS6cjs = require('./chunk-4ZVKDHS6.cjs');
155
153
 
156
154
 
157
155
  var _chunk3HLQTOVUcjs = require('./chunk-3HLQTOVU.cjs');
@@ -165,7 +163,7 @@ var _chunk47JV57DAcjs = require('./chunk-47JV57DA.cjs');
165
163
 
166
164
 
167
165
 
168
- var _chunkTQJ35BBWcjs = require('./chunk-TQJ35BBW.cjs');
166
+ var _chunkXFUPWRKTcjs = require('./chunk-XFUPWRKT.cjs');
169
167
 
170
168
 
171
169
 
@@ -173,7 +171,7 @@ var _chunkTQJ35BBWcjs = require('./chunk-TQJ35BBW.cjs');
173
171
  var _chunkW53Z4WDIcjs = require('./chunk-W53Z4WDI.cjs');
174
172
 
175
173
 
176
- var _chunkNXOZRI3Bcjs = require('./chunk-NXOZRI3B.cjs');
174
+ var _chunkIM422XKUcjs = require('./chunk-IM422XKU.cjs');
177
175
 
178
176
 
179
177
  var _chunk4EBC7EMWcjs = require('./chunk-4EBC7EMW.cjs');
@@ -194,7 +192,7 @@ var _chunk4EBC7EMWcjs = require('./chunk-4EBC7EMW.cjs');
194
192
 
195
193
 
196
194
 
197
- var _chunkQYDGIXQ5cjs = require('./chunk-QYDGIXQ5.cjs');
195
+ var _chunkU3A46QFDcjs = require('./chunk-U3A46QFD.cjs');
198
196
 
199
197
 
200
198
 
@@ -214,6 +212,9 @@ var _chunkL2GUEYHRcjs = require('./chunk-L2GUEYHR.cjs');
214
212
  var _chunkIIHZ2BEEcjs = require('./chunk-IIHZ2BEE.cjs');
215
213
 
216
214
 
215
+ var _chunkZ43CIBURcjs = require('./chunk-Z43CIBUR.cjs');
216
+
217
+
217
218
 
218
219
  var _chunk6JHZPB52cjs = require('./chunk-6JHZPB52.cjs');
219
220
 
@@ -280,7 +281,7 @@ var _chunkNW3DL2PMcjs = require('./chunk-NW3DL2PM.cjs');
280
281
  var _chunkSHDCKRP4cjs = require('./chunk-SHDCKRP4.cjs');
281
282
 
282
283
 
283
- var _chunk5P65LXGUcjs = require('./chunk-5P65LXGU.cjs');
284
+ var _chunkWSQ3S3NVcjs = require('./chunk-WSQ3S3NV.cjs');
284
285
 
285
286
 
286
287
  var _chunkCYOTNHDFcjs = require('./chunk-CYOTNHDF.cjs');
@@ -308,7 +309,7 @@ var _chunk7U4XF76Rcjs = require('./chunk-7U4XF76R.cjs');
308
309
  var _chunk2OF5RPVUcjs = require('./chunk-2OF5RPVU.cjs');
309
310
 
310
311
 
311
- var _chunk2NKNP4AHcjs = require('./chunk-2NKNP4AH.cjs');
312
+ var _chunkHYL372GWcjs = require('./chunk-HYL372GW.cjs');
312
313
 
313
314
 
314
315
  var _chunkY3DO7BIJcjs = require('./chunk-Y3DO7BIJ.cjs');
@@ -661,7 +662,7 @@ async function compileFarmDocsManifest(docs, options) {
661
662
  isPathGuarded: options.isPathGuarded,
662
663
  basePath
663
664
  });
664
- const apiHandler = _chunkBLZCAFGJcjs.createFarmDocsAPIHandler.call(void 0, {
665
+ const apiHandler = _chunkCXHVRHM2cjs.createFarmDocsAPIHandler.call(void 0, {
665
666
  rootDir: options.root,
666
667
  srcDir: options.srcDir,
667
668
  docs,
@@ -896,15 +897,26 @@ function encodeFarmBuildJSONPlaceholder(value) {
896
897
 
897
898
  // src/nitro/islands-react-chunk.ts
898
899
  var REACT_MODULE = /[\\/]node_modules[\\/](?:react|react-dom|scheduler)[\\/]/;
899
- function createFarmIslandsReactChunkGroup() {
900
+ var REACT_DOM_MODULE = /[\\/]node_modules[\\/]react-dom[\\/]/;
901
+ var FARM_EAGER_COMPILE_HINT = "//# allFunctionsCalledOnLoad";
902
+ function createFarmIslandsReactOutput() {
900
903
  let entryImportsReact;
901
904
  return {
902
- debugName: "react",
903
- name(moduleId, context) {
904
- if (!REACT_MODULE.test(moduleId)) return null;
905
- _nullishCoalesce(entryImportsReact, () => ( (entryImportsReact = reactLoadsWithAnEntry(moduleId, context))));
906
- return entryImportsReact ? null : "react";
907
- }
905
+ codeSplitting: {
906
+ groups: [
907
+ {
908
+ debugName: "react",
909
+ name(moduleId, context) {
910
+ if (!REACT_MODULE.test(moduleId)) return null;
911
+ _nullishCoalesce(entryImportsReact, () => ( (entryImportsReact = reactLoadsWithAnEntry(moduleId, context))));
912
+ return entryImportsReact ? null : "react";
913
+ }
914
+ }
915
+ ]
916
+ },
917
+ // After minification, so the hint stays the chunk's first line; its source map accounts for it.
918
+ // Rolldown adds a line after any string, an empty one too, so other chunks get none.
919
+ postBanner: ((chunk) => entryImportsReact === false && chunk.moduleIds.some((id) => REACT_DOM_MODULE.test(id)) ? FARM_EAGER_COMPILE_HINT : void 0)
908
920
  };
909
921
  }
910
922
  function reactLoadsWithAnEntry(moduleId, context) {
@@ -928,14 +940,25 @@ function reactLoadsWithAnEntry(moduleId, context) {
928
940
  }
929
941
  return false;
930
942
  }
931
- function configuresFarmClientChunks(vite) {
932
- const build2 = _optionalChain([vite, 'optionalAccess', _10 => _10.build]);
933
- const outputs = [_optionalChain([build2, 'optionalAccess', _11 => _11.rollupOptions, 'optionalAccess', _12 => _12.output]), _optionalChain([build2, 'optionalAccess', _13 => _13.rolldownOptions, 'optionalAccess', _14 => _14.output])].flat();
934
- return outputs.some(
935
- (output) => !!output && typeof output === "object" && ["manualChunks", "advancedChunks", "codeSplitting", "inlineDynamicImports"].some(
936
- (key) => output[key] !== void 0
937
- )
938
- );
943
+ var CHUNKING_OPTIONS = [
944
+ "manualChunks",
945
+ "advancedChunks",
946
+ "codeSplitting",
947
+ "inlineDynamicImports"
948
+ ];
949
+ function createFarmIslandsReactChunkPlugin() {
950
+ return {
951
+ name: "farm-islands-react-chunk",
952
+ enforce: "post",
953
+ outputOptions: {
954
+ order: "post",
955
+ handler(options) {
956
+ if (CHUNKING_OPTIONS.some((key) => options[key] !== void 0)) return null;
957
+ const { codeSplitting, postBanner } = createFarmIslandsReactOutput();
958
+ return { ...options, codeSplitting, postBanner: _nullishCoalesce(options.postBanner, () => ( postBanner)) };
959
+ }
960
+ }
961
+ };
939
962
  }
940
963
 
941
964
  // src/nitro/client-route-table.ts
@@ -1192,7 +1215,7 @@ function validateFarmRouteRuntimeDeployment(manifest, preset) {
1192
1215
  `Route "${route.pattern}" requires the ${route.runtime} runtime, but preset "${preset}" emits ${runtime} functions. Choose a compatible preset or change the route runtime.`
1193
1216
  );
1194
1217
  }
1195
- if (_optionalChain([route, 'access', _15 => _15.regions, 'optionalAccess', _16 => _16.length]) && preset !== "vercel") {
1218
+ if (_optionalChain([route, 'access', _10 => _10.regions, 'optionalAccess', _11 => _11.length]) && preset !== "vercel") {
1196
1219
  warnings.add(
1197
1220
  `Preset "${preset}" does not map per-route regions; Farm kept them in ${FARM_ROUTE_RUNTIME_MANIFEST} for deployment adapters.`
1198
1221
  );
@@ -1239,7 +1262,7 @@ async function createFarmVercelRouteRuntimeFunctions(outputDir, manifest, fs5, b
1239
1262
  const destinations = /* @__PURE__ */ new Map();
1240
1263
  let groupIndex = 0;
1241
1264
  for (const [key, group] of groups) {
1242
- if (!_optionalChain([group, 'access', _17 => _17.config, 'access', _18 => _18.regions, 'optionalAccess', _19 => _19.length]) && !group.config.maxDuration) {
1265
+ if (!_optionalChain([group, 'access', _12 => _12.config, 'access', _13 => _13.regions, 'optionalAccess', _14 => _14.length]) && !group.config.maxDuration) {
1243
1266
  destinations.set(key, "/__nitro");
1244
1267
  continue;
1245
1268
  }
@@ -1289,14 +1312,14 @@ async function configureVercelFunction(functionDir, config, fs5) {
1289
1312
  const current = JSON.parse(await fs5.readFile(configPath, "utf8"));
1290
1313
  const next = {
1291
1314
  ...current,
1292
- ..._optionalChain([config, 'access', _20 => _20.regions, 'optionalAccess', _21 => _21.length]) ? { regions: config.regions } : {},
1315
+ ..._optionalChain([config, 'access', _15 => _15.regions, 'optionalAccess', _16 => _16.length]) ? { regions: config.regions } : {},
1293
1316
  ...config.maxDuration ? { maxDuration: config.maxDuration } : {}
1294
1317
  };
1295
1318
  await fs5.writeFile(configPath, `${JSON.stringify(next, null, 2)}
1296
1319
  `);
1297
1320
  }
1298
1321
  function hasVercelFunctionControls(route) {
1299
- return Boolean(_optionalChain([route, 'access', _22 => _22.regions, 'optionalAccess', _23 => _23.length]) || route.maxDuration);
1322
+ return Boolean(_optionalChain([route, 'access', _17 => _17.regions, 'optionalAccess', _18 => _18.length]) || route.maxDuration);
1300
1323
  }
1301
1324
  function compareRuntimeRoutes(left, right) {
1302
1325
  const kindOrder = { page: 0, api: 0, metadata: 0, rule: 1 };
@@ -1341,7 +1364,7 @@ var FARM_HASHED_ASSET_DIRS = ["assets", "chunks"];
1341
1364
  var LITERAL_ROUTE_PATH = /^\/[\w.~@/-]+$/;
1342
1365
  function planFarmImmutableAssets(options) {
1343
1366
  const cacheRulePatterns = Object.entries(_nullishCoalesce(options.routeRules, () => ( {}))).filter(
1344
- ([, rule]) => Object.keys(_nullishCoalesce(_optionalChain([rule, 'optionalAccess', _24 => _24.headers]), () => ( {}))).some((name) => name.toLowerCase() === "cache-control")
1367
+ ([, rule]) => Object.keys(_nullishCoalesce(_optionalChain([rule, 'optionalAccess', _19 => _19.headers]), () => ( {}))).some((name) => name.toLowerCase() === "cache-control")
1345
1368
  ).map(([pattern]) => pattern);
1346
1369
  const isImmutable = (file) => isFarmImmutableAssetPath(file) && !cacheRulePatterns.some((pattern) => _chunkIUKBPBM7cjs.farmRouteRuleMatches.call(void 0, pattern, file));
1347
1370
  const routeDirs = new Set(
@@ -1469,7 +1492,7 @@ function resolveBundleFileName(chunkFileName, relativeUrl) {
1469
1492
  function replaceServerFileReferences(bundle, chunkFileName, code, replace) {
1470
1493
  return code.replace(SERVER_FILE_URL_RE, (reference, _quote, relativeUrl) => {
1471
1494
  const target = resolveBundleFileName(chunkFileName, relativeUrl);
1472
- return target && _optionalChain([bundle, 'access', _25 => _25[target], 'optionalAccess', _26 => _26.type]) === "asset" ? replace(target) : reference;
1495
+ return target && _optionalChain([bundle, 'access', _20 => _20[target], 'optionalAccess', _21 => _21.type]) === "asset" ? replace(target) : reference;
1473
1496
  });
1474
1497
  }
1475
1498
  function collectServerReadSSRAssets(bundle) {
@@ -1522,7 +1545,7 @@ function assertServerReadSSRAssetsSupported(bundle, preset, root) {
1522
1545
  if (assets.length === 0) return;
1523
1546
  const sources = assets.map((fileName) => {
1524
1547
  const output = bundle[fileName];
1525
- const original = _optionalChain([output, 'optionalAccess', _27 => _27.type]) === "asset" ? _optionalChain([output, 'access', _28 => _28.originalFileNames, 'optionalAccess', _29 => _29[0]]) : void 0;
1548
+ const original = _optionalChain([output, 'optionalAccess', _22 => _22.type]) === "asset" ? _optionalChain([output, 'access', _23 => _23.originalFileNames, 'optionalAccess', _24 => _24[0]]) : void 0;
1526
1549
  if (!original) return fileName;
1527
1550
  return _path2.default.relative(root, _path2.default.resolve(root, original)).split(_path2.default.sep).join("/");
1528
1551
  });
@@ -1541,7 +1564,7 @@ function createServerReadSSRAssetsPlugin(bundle, ssrOutputDir) {
1541
1564
  transform(code, id) {
1542
1565
  if (!code.includes("import.meta.url")) return null;
1543
1566
  const chunkFileName = _path2.default.relative(ssrOutputDir, id.split("?", 1)[0]).split(_path2.default.sep).join("/");
1544
- if (_optionalChain([bundle, 'access', _30 => _30[chunkFileName], 'optionalAccess', _31 => _31.type]) !== "chunk") return null;
1567
+ if (_optionalChain([bundle, 'access', _25 => _25[chunkFileName], 'optionalAccess', _26 => _26.type]) !== "chunk") return null;
1545
1568
  let changed = false;
1546
1569
  const transformed = replaceServerFileReferences(
1547
1570
  bundle,
@@ -1637,7 +1660,7 @@ export default async function farmNetlifyHandler(request, context) {
1637
1660
  var PLATFORM_CONFIG_KEYS = /* @__PURE__ */ new Set(["desktop", "mobile"]);
1638
1661
  var CONFIG_FACTORIES = /* @__PURE__ */ new Set(["defineConfig", "defineFarmConfig"]);
1639
1662
  function isConfigObject(node) {
1640
- return _optionalChain([node, 'optionalAccess', _32 => _32.type]) === "ObjectExpression";
1663
+ return _optionalChain([node, 'optionalAccess', _27 => _27.type]) === "ObjectExpression";
1641
1664
  }
1642
1665
  function propertyName(property) {
1643
1666
  if (property.type !== "Property" || property.computed) return void 0;
@@ -1658,7 +1681,7 @@ function collectConfigObjects(node, found) {
1658
1681
  }
1659
1682
  if (current.type === "CallExpression") {
1660
1683
  const callee = current.callee;
1661
- const name = callee.type === "Identifier" ? callee.name : _optionalChain([callee, 'access', _33 => _33.property, 'optionalAccess', _34 => _34.name]);
1684
+ const name = callee.type === "Identifier" ? callee.name : _optionalChain([callee, 'access', _28 => _28.property, 'optionalAccess', _29 => _29.name]);
1662
1685
  const argument = current.arguments[0];
1663
1686
  if (name && CONFIG_FACTORIES.has(name) && isConfigObject(argument)) found.push(argument);
1664
1687
  }
@@ -1691,7 +1714,7 @@ function stripPlatformConfigSource(code, parse) {
1691
1714
  const trailingComma = /^\s*,/.exec(code.slice(properties[last].end));
1692
1715
  removals.push([
1693
1716
  properties[first].start,
1694
- properties[last].end + (_nullishCoalesce(_optionalChain([trailingComma, 'optionalAccess', _35 => _35[0], 'access', _36 => _36.length]), () => ( 0)))
1717
+ properties[last].end + (_nullishCoalesce(_optionalChain([trailingComma, 'optionalAccess', _30 => _30[0], 'access', _31 => _31.length]), () => ( 0)))
1695
1718
  ]);
1696
1719
  }
1697
1720
  first = last;
@@ -1718,7 +1741,7 @@ function farmStripPlatformConfigPlugin(configFiles) {
1718
1741
  // removed block used (`readFileSync` for a version, say).
1719
1742
  enforce: "pre",
1720
1743
  transform: {
1721
- filter: { id: _chunkP253SZJFcjs.fileNamePattern.call(void 0, configFiles) },
1744
+ filter: { id: _chunkTI4BZV6Mcjs.fileNamePattern.call(void 0, configFiles) },
1722
1745
  async handler(code, id) {
1723
1746
  const file = id.split("?", 1)[0];
1724
1747
  if (!files.has(_path2.default.resolve(file)) && !files.has(realPath(file))) return null;
@@ -1771,7 +1794,7 @@ function precompileFarmMarkdownPages(bodies, coreRoot) {
1771
1794
  return;
1772
1795
  }
1773
1796
  worker.once("message", (entries) => {
1774
- void _optionalChain([worker, 'optionalAccess', _37 => _37.terminate, 'call', _38 => _38()]);
1797
+ void _optionalChain([worker, 'optionalAccess', _32 => _32.terminate, 'call', _33 => _33()]);
1775
1798
  done(entries);
1776
1799
  });
1777
1800
  worker.once("error", () => done());
@@ -1780,7 +1803,7 @@ function precompileFarmMarkdownPages(bodies, coreRoot) {
1780
1803
  return {
1781
1804
  pages,
1782
1805
  dispose() {
1783
- void _optionalChain([worker, 'optionalAccess', _39 => _39.terminate, 'call', _40 => _40()]);
1806
+ void _optionalChain([worker, 'optionalAccess', _34 => _34.terminate, 'call', _35 => _35()]);
1784
1807
  }
1785
1808
  };
1786
1809
  }
@@ -1862,7 +1885,7 @@ function literalMatcher(node) {
1862
1885
  if (node.type === "Literal" && node.regex)
1863
1886
  return new RegExp(node.regex.pattern, node.regex.flags);
1864
1887
  if (node.type === "TemplateLiteral" && node.expressions.length === 0) {
1865
- return _nullishCoalesce(_optionalChain([node, 'access', _41 => _41.quasis, 'access', _42 => _42[0], 'optionalAccess', _43 => _43.value, 'optionalAccess', _44 => _44.cooked]), () => ( void 0));
1888
+ return _nullishCoalesce(_optionalChain([node, 'access', _36 => _36.quasis, 'access', _37 => _37[0], 'optionalAccess', _38 => _38.value, 'optionalAccess', _39 => _39.cooked]), () => ( void 0));
1866
1889
  }
1867
1890
  return void 0;
1868
1891
  }
@@ -1886,7 +1909,7 @@ function readStaticMiddlewareConfig(program) {
1886
1909
  let found = null;
1887
1910
  for (const statement of program.body) {
1888
1911
  if (statement.type === "ExportNamedDeclaration" && !statement.declaration) {
1889
- if (statement.specifiers.some((specifier) => _optionalChain([specifier, 'access', _45 => _45.exported, 'optionalAccess', _46 => _46.name]) === "config")) {
1912
+ if (statement.specifiers.some((specifier) => _optionalChain([specifier, 'access', _40 => _40.exported, 'optionalAccess', _41 => _41.name]) === "config")) {
1890
1913
  return "unknown";
1891
1914
  }
1892
1915
  continue;
@@ -1894,14 +1917,14 @@ function readStaticMiddlewareConfig(program) {
1894
1917
  const declaration = statement.type === "ExportNamedDeclaration" ? statement.declaration : null;
1895
1918
  if (!declaration || declaration.type !== "VariableDeclaration") continue;
1896
1919
  for (const declarator of declaration.declarations) {
1897
- if (_optionalChain([declarator, 'access', _47 => _47.id, 'optionalAccess', _48 => _48.type]) !== "Identifier" || declarator.id.name !== "config") continue;
1920
+ if (_optionalChain([declarator, 'access', _42 => _42.id, 'optionalAccess', _43 => _43.type]) !== "Identifier" || declarator.id.name !== "config") continue;
1898
1921
  if (declaration.kind !== "const" || !declarator.init) return "unknown";
1899
1922
  const init = unwrap(declarator.init);
1900
1923
  if (init.type !== "ObjectExpression") return "unknown";
1901
1924
  const config = {};
1902
1925
  for (const property of init.properties) {
1903
1926
  if (property.type !== "Property" || property.computed) return "unknown";
1904
- const key = _nullishCoalesce(_optionalChain([property, 'access', _49 => _49.key, 'optionalAccess', _50 => _50.name]), () => ( _optionalChain([property, 'access', _51 => _51.key, 'optionalAccess', _52 => _52.value])));
1927
+ const key = _nullishCoalesce(_optionalChain([property, 'access', _44 => _44.key, 'optionalAccess', _45 => _45.name]), () => ( _optionalChain([property, 'access', _46 => _46.key, 'optionalAccess', _47 => _47.value])));
1905
1928
  if (key === "runtime") {
1906
1929
  const runtime = literalMatcher(unwrap(property.value));
1907
1930
  if (runtime === "edge" || runtime === "nodejs") config.runtime = runtime;
@@ -1922,7 +1945,7 @@ async function readMiddlewareFileConfig(filePath) {
1922
1945
  try {
1923
1946
  const [{ readFile: readFile2 }, vite] = await Promise.all([import("fs/promises"), import("vite")]);
1924
1947
  const parsed = vite.parseSync(filePath, await readFile2(filePath, "utf8"));
1925
- if (_optionalChain([parsed, 'access', _53 => _53.errors, 'optionalAccess', _54 => _54.length])) return "unknown";
1948
+ if (_optionalChain([parsed, 'access', _48 => _48.errors, 'optionalAccess', _49 => _49.length])) return "unknown";
1926
1949
  return readStaticMiddlewareConfig(parsed.program);
1927
1950
  } catch (e14) {
1928
1951
  return "unknown";
@@ -1941,7 +1964,7 @@ function farmTargetRunsEdgeMiddleware(preset) {
1941
1964
  return preset === "vercel";
1942
1965
  }
1943
1966
  function isFarmEdgeMiddlewareRoute(route) {
1944
- return typeof route.config === "object" && _optionalChain([route, 'access', _55 => _55.config, 'optionalAccess', _56 => _56.runtime]) === "edge";
1967
+ return typeof route.config === "object" && _optionalChain([route, 'access', _50 => _50.config, 'optionalAccess', _51 => _51.runtime]) === "edge";
1945
1968
  }
1946
1969
  function escapeRegExp3(value) {
1947
1970
  return value.replace(/[.*+?^${}()|[\]\\]/g, "\\$&");
@@ -1978,7 +2001,7 @@ export default createFarmVercelEdgeMiddleware({
1978
2001
  ${modules.join("\n")}
1979
2002
  ],
1980
2003
  i18n: ${JSON.stringify(config.i18n)},
1981
- server: ${JSON.stringify({ trustProxy: _optionalChain([config, 'access', _57 => _57.server, 'optionalAccess', _58 => _58.trustProxy]) === true })},
2004
+ server: ${JSON.stringify({ trustProxy: _optionalChain([config, 'access', _52 => _52.server, 'optionalAccess', _53 => _53.trustProxy]) === true })},
1982
2005
  apiBasePath: ${JSON.stringify(_chunk2OF5RPVUcjs.resolveFarmAPIServerBasePath.call(void 0, config.api))},
1983
2006
  notFoundPath: ${JSON.stringify(_chunkD22BUQKWcjs.applyFarmBasePath.call(void 0, FARM_VERCEL_EDGE_NOT_FOUND_PATH, config.basePath))},
1984
2007
  pages: ${JSON.stringify(toFarmVercelEdgeGuardedUrls(guardedPages, config.basePath))},
@@ -2037,7 +2060,7 @@ async function writeFarmVercelEdgeMiddlewareFunction(options) {
2037
2060
  logLevel: "silent",
2038
2061
  plugins: [edgeNodeModulesPlugin(coreDir, unsupported)],
2039
2062
  resolve: {
2040
- alias: _chunkP253SZJFcjs.createFarmSourceAlias.call(void 0, root, config.srcDir),
2063
+ alias: _chunkTI4BZV6Mcjs.createFarmSourceAlias.call(void 0, root, config.srcDir),
2041
2064
  conditionNames: ["edge-light", "worker", "browser", "import", "module", "default"]
2042
2065
  },
2043
2066
  transform: {
@@ -2269,7 +2292,7 @@ function createPrerenderRuntimeResolverPlugin(root, resolveNitroEntry = resolveN
2269
2292
  return {
2270
2293
  name: "farm-prerender-runtime-resolver",
2271
2294
  async resolveId(id, _importer, options) {
2272
- if (_optionalChain([options, 'access', _59 => _59.custom, 'optionalAccess', _60 => _60.farmPrerenderRuntimeResolve])) return null;
2295
+ if (_optionalChain([options, 'access', _54 => _54.custom, 'optionalAccess', _55 => _55.farmPrerenderRuntimeResolve])) return null;
2273
2296
  if (id.startsWith("\0") || id.startsWith(".") || id.startsWith("#") || id.startsWith("virtual:") || _path2.default.isAbsolute(id) || NODE_BUILTIN_MODULES.has(id)) {
2274
2297
  return null;
2275
2298
  }
@@ -2439,7 +2462,7 @@ function createOmittedMetadataImageRuntimePlugin(externalizeOtherImports) {
2439
2462
  return {
2440
2463
  name: "farm-omitted-metadata-image-runtime",
2441
2464
  resolveId: {
2442
- filter: { id: _chunkP253SZJFcjs.exactIdPattern.call(void 0, ["@vercel/og"]) },
2465
+ filter: { id: _chunkTI4BZV6Mcjs.exactIdPattern.call(void 0, ["@vercel/og"]) },
2443
2466
  handler(source, importer) {
2444
2467
  if (source !== "@vercel/og") return null;
2445
2468
  const fromCoreRuntime = importer !== void 0 && isFarmCoreModule(importer) && !/^og\.[cm]?[jt]sx?$/.test(_path2.default.basename(importer.split("?", 1)[0]));
@@ -2448,7 +2471,7 @@ function createOmittedMetadataImageRuntimePlugin(externalizeOtherImports) {
2448
2471
  }
2449
2472
  },
2450
2473
  load: {
2451
- filter: { id: _chunkP253SZJFcjs.exactIdPattern.call(void 0, [FARM_OMITTED_METADATA_IMAGE_RUNTIME_ID]) },
2474
+ filter: { id: _chunkTI4BZV6Mcjs.exactIdPattern.call(void 0, [FARM_OMITTED_METADATA_IMAGE_RUNTIME_ID]) },
2452
2475
  handler(id) {
2453
2476
  if (id !== FARM_OMITTED_METADATA_IMAGE_RUNTIME_ID) return null;
2454
2477
  return `
@@ -2476,8 +2499,8 @@ function readVercelOgManifest(file) {
2476
2499
  }
2477
2500
  function resolveVercelOgConditionEntry(resolvedId, condition) {
2478
2501
  const vercelOg = readVercelOgManifest(resolvedId);
2479
- const entry = _optionalChain([vercelOg, 'optionalAccess', _61 => _61.manifest, 'access', _62 => _62.exports, 'optionalAccess', _63 => _63["."], 'optionalAccess', _64 => _64[condition]]);
2480
- const file = typeof entry === "string" ? entry : _optionalChain([entry, 'optionalAccess', _65 => _65.default]);
2502
+ const entry = _optionalChain([vercelOg, 'optionalAccess', _56 => _56.manifest, 'access', _57 => _57.exports, 'optionalAccess', _58 => _58["."], 'optionalAccess', _59 => _59[condition]]);
2503
+ const file = typeof entry === "string" ? entry : _optionalChain([entry, 'optionalAccess', _60 => _60.default]);
2481
2504
  return vercelOg && typeof file === "string" ? _path2.default.join(vercelOg.dir, file) : null;
2482
2505
  }
2483
2506
  function createEdgeMetadataImageRuntimePlugin({
@@ -2493,7 +2516,7 @@ function createEdgeMetadataImageRuntimePlugin({
2493
2516
  const edgeEntry = resolveVercelOgConditionEntry(resolved.id, condition);
2494
2517
  return edgeEntry ? { ...resolved, id: edgeEntry } : resolved;
2495
2518
  }
2496
- if (wasm !== "module" || !source.endsWith(".wasm?module") || !_optionalChain([importer, 'optionalAccess', _66 => _66.replace, 'call', _67 => _67(/\\/g, "/"), 'access', _68 => _68.includes, 'call', _69 => _69("/@vercel/og/")])) {
2519
+ if (wasm !== "module" || !source.endsWith(".wasm?module") || !_optionalChain([importer, 'optionalAccess', _61 => _61.replace, 'call', _62 => _62(/\\/g, "/"), 'access', _63 => _63.includes, 'call', _64 => _64("/@vercel/og/")])) {
2497
2520
  return null;
2498
2521
  }
2499
2522
  const resolvedPath = _path2.default.resolve(_path2.default.dirname(importer.split("?", 1)[0]), source);
@@ -2515,7 +2538,7 @@ function createVercelOgFontInlinePlugin(runtime = "Cloudflare Workers") {
2515
2538
  return `Promise.resolve({ arrayBuffer: () => Uint8Array.from(atob(${JSON.stringify(encoded)}), (character) => character.charCodeAt(0)).buffer })`;
2516
2539
  });
2517
2540
  if (inlined !== code) return { code: inlined, map: null };
2518
- const version = _nullishCoalesce(_optionalChain([readVercelOgManifest, 'call', _70 => _70(file), 'optionalAccess', _71 => _71.manifest, 'access', _72 => _72.version]), () => ( "(unknown version)"));
2541
+ const version = _nullishCoalesce(_optionalChain([readVercelOgManifest, 'call', _65 => _65(file), 'optionalAccess', _66 => _66.manifest, 'access', _67 => _67.version]), () => ( "(unknown version)"));
2519
2542
  this.error(
2520
2543
  `@vercel/og ${version} cannot be bundled for ${runtime}: ${file} does not load its default font with fetch(new URL("./<font>.ttf", import.meta.url)), the pattern Farm inlines because an edge function cannot fetch it. Install a @vercel/og version whose edge build does, such as 1.0.1.`
2521
2544
  );
@@ -2526,7 +2549,7 @@ function createMetadataImageWasmPlugin() {
2526
2549
  return {
2527
2550
  name: "farm-metadata-image-wasm",
2528
2551
  resolveId(source, importer) {
2529
- if (!source.endsWith(".wasm?module") || !_optionalChain([importer, 'optionalAccess', _73 => _73.replace, 'call', _74 => _74(/\\/g, "/"), 'access', _75 => _75.includes, 'call', _76 => _76("/@vercel/og/")])) {
2552
+ if (!source.endsWith(".wasm?module") || !_optionalChain([importer, 'optionalAccess', _68 => _68.replace, 'call', _69 => _69(/\\/g, "/"), 'access', _70 => _70.includes, 'call', _71 => _71("/@vercel/og/")])) {
2530
2553
  return null;
2531
2554
  }
2532
2555
  const requestPath = source.slice(0, -"?module".length);
@@ -2602,9 +2625,9 @@ function hasFarmRuntimeConfigModule(config, configModulePath) {
2602
2625
  return Boolean(configModulePath || (config.layers || []).some((layer) => layer.configFile));
2603
2626
  }
2604
2627
  function nameCodeSplittingGroups(bundlerConfig) {
2605
- const outputs = _optionalChain([bundlerConfig, 'optionalAccess', _77 => _77.output]);
2628
+ const outputs = _optionalChain([bundlerConfig, 'optionalAccess', _72 => _72.output]);
2606
2629
  for (const output of Array.isArray(outputs) ? outputs : [outputs]) {
2607
- const groups = _optionalChain([output, 'optionalAccess', _78 => _78.codeSplitting, 'optionalAccess', _79 => _79.groups]);
2630
+ const groups = _optionalChain([output, 'optionalAccess', _73 => _73.codeSplitting, 'optionalAccess', _74 => _74.groups]);
2608
2631
  if (!Array.isArray(groups)) continue;
2609
2632
  groups.forEach((group, index) => {
2610
2633
  if (group && typeof group.name === "function" && !group.debugName) {
@@ -2665,9 +2688,9 @@ function restoreLiteralModuleSpecifiers(code, fileName, { parseSync, Visitor })
2665
2688
  throw new Error(`Failed to minify ${fileName}: ${parsed.errors[0].message}`);
2666
2689
  }
2667
2690
  const restore = (node) => {
2668
- if (_optionalChain([node, 'optionalAccess', _80 => _80.type]) !== "TemplateLiteral") return;
2691
+ if (_optionalChain([node, 'optionalAccess', _75 => _75.type]) !== "TemplateLiteral") return;
2669
2692
  const template = node;
2670
- const value = _optionalChain([template, 'access', _81 => _81.quasis, 'access', _82 => _82[0], 'optionalAccess', _83 => _83.value, 'access', _84 => _84.cooked]);
2693
+ const value = _optionalChain([template, 'access', _76 => _76.quasis, 'access', _77 => _77[0], 'optionalAccess', _78 => _78.value, 'access', _79 => _79.cooked]);
2671
2694
  if (template.expressions.length > 0 || typeof value !== "string") return;
2672
2695
  replacements.push({
2673
2696
  start: template.start,
@@ -2825,7 +2848,7 @@ async function discoverMiddlewareRoutes(appDir) {
2825
2848
  return Array.from(routes.values()).sort(_chunkSHDCKRP4cjs.compareMiddlewareRouteLocations).map(({ path: routePath, filePath }) => ({ path: routePath, filePath }));
2826
2849
  }
2827
2850
  function assertFarmDocsRuntimeSupported(config, preset) {
2828
- if (!_optionalChain([config, 'access', _85 => _85.docs, 'optionalAccess', _86 => _86.enabled]) || !_optionalChain([config, 'access', _87 => _87.docs, 'access', _88 => _88.adapter, 'optionalAccess', _89 => _89.server]) || _chunkNLBHLPEOcjs.getFarmPresetRuntime.call(void 0, preset) !== "edge" || Boolean(config.docs.adapter.edgeCompiler)) {
2851
+ if (!_optionalChain([config, 'access', _80 => _80.docs, 'optionalAccess', _81 => _81.enabled]) || !_optionalChain([config, 'access', _82 => _82.docs, 'access', _83 => _83.adapter, 'optionalAccess', _84 => _84.server]) || _chunkNLBHLPEOcjs.getFarmPresetRuntime.call(void 0, preset) !== "edge" || Boolean(config.docs.adapter.edgeCompiler)) {
2829
2852
  return;
2830
2853
  }
2831
2854
  throw new Error(
@@ -3006,7 +3029,7 @@ ${islandsErrors.map((error) => ` - ${error}`).join("\n")}`
3006
3029
  );
3007
3030
  }
3008
3031
  }
3009
- _optionalChain([sourceSnapshot, 'optionalAccess', _90 => _90.clear, 'call', _91 => _91()]);
3032
+ _optionalChain([sourceSnapshot, 'optionalAccess', _85 => _85.clear, 'call', _86 => _86()]);
3010
3033
  const ssrResult = ssrBuildResult.value;
3011
3034
  const routeRuntimeManifest = routeRuntimeManifestResult.value;
3012
3035
  const runtimeValidation = validateFarmRouteRuntimeDeployment(routeRuntimeManifest, preset);
@@ -3038,7 +3061,7 @@ ${islandsErrors.map((error) => ` - ${error}`).join("\n")}`
3038
3061
  configuredHeaderRoutes,
3039
3062
  nitroBuilderResultPromise,
3040
3063
  lifecyclePluginManager,
3041
- _optionalChain([markdownPrecompile, 'optionalAccess', _92 => _92.pages])
3064
+ _optionalChain([markdownPrecompile, 'optionalAccess', _87 => _87.pages])
3042
3065
  );
3043
3066
  const runtimeManifestPath = await writeFarmRouteRuntimeManifest(
3044
3067
  _path2.default.join(root, distDir),
@@ -3059,8 +3082,8 @@ ${islandsErrors.map((error) => ` - ${error}`).join("\n")}`
3059
3082
  _chunk7U4XF76Rcjs.logger.error(`\u274C Build failed: ${error}`);
3060
3083
  throw error;
3061
3084
  } finally {
3062
- _optionalChain([rendererBuild, 'optionalAccess', _93 => _93.abort, 'call', _94 => _94()]);
3063
- _optionalChain([markdownPrecompile, 'optionalAccess', _95 => _95.dispose, 'call', _96 => _96()]);
3085
+ _optionalChain([rendererBuild, 'optionalAccess', _88 => _88.abort, 'call', _89 => _89()]);
3086
+ _optionalChain([markdownPrecompile, 'optionalAccess', _90 => _90.dispose, 'call', _91 => _91()]);
3064
3087
  }
3065
3088
  }
3066
3089
  function collectFarmPrerenderedMarkdownBodies(pageRoutes) {
@@ -3083,7 +3106,7 @@ function varyFarmNitroCacheRules(rules, headerNames) {
3083
3106
  if (headerNames.length === 0) return rules;
3084
3107
  return Object.fromEntries(
3085
3108
  Object.entries(rules).map(([source, rule]) => {
3086
- const cached = _optionalChain([rule, 'optionalAccess', _97 => _97.swr]) !== void 0 && rule.swr !== false || _optionalChain([rule, 'optionalAccess', _98 => _98.cache]) !== void 0 && rule.cache !== false;
3109
+ const cached = _optionalChain([rule, 'optionalAccess', _92 => _92.swr]) !== void 0 && rule.swr !== false || _optionalChain([rule, 'optionalAccess', _93 => _93.cache]) !== void 0 && rule.cache !== false;
3087
3110
  if (!cached || rule.cache === false) return [source, rule];
3088
3111
  const cache = rule.cache && typeof rule.cache === "object" ? rule.cache : {};
3089
3112
  const varies = [
@@ -3112,7 +3135,7 @@ async function writeFarmVideoPlayerToClient(outputDir) {
3112
3135
  const filePath = _path2.default.join(outputDir, _chunkY3DO7BIJcjs.FARM_VIDEO_PLAYER_PATH.slice(1));
3113
3136
  await fs5.mkdir(_path2.default.dirname(filePath), { recursive: true });
3114
3137
  try {
3115
- await fs5.writeFile(filePath, _chunkP253SZJFcjs.FARM_VIDEO_PLAYER_HTML, { flag: "wx" });
3138
+ await fs5.writeFile(filePath, _chunkTI4BZV6Mcjs.FARM_VIDEO_PLAYER_HTML, { flag: "wx" });
3116
3139
  } catch (error) {
3117
3140
  if (error.code !== "EEXIST") throw error;
3118
3141
  }
@@ -3146,7 +3169,7 @@ async function mergeBuiltFontCss(outputDir, fontCssSource) {
3146
3169
  }
3147
3170
  const normalizedFontCss = typeof fontCss === "string" ? fontCss : Buffer.from(fontCss).toString("utf8");
3148
3171
  await fs5.writeFile(fontCssPath, normalizedFontCss);
3149
- await fs5.writeFile(clientCssPath, _chunkP253SZJFcjs.mergeFarmFontCss.call(void 0, clientCss, normalizedFontCss));
3172
+ await fs5.writeFile(clientCssPath, _chunkTI4BZV6Mcjs.mergeFarmFontCss.call(void 0, clientCss, normalizedFontCss));
3150
3173
  }
3151
3174
  function importsFarmClientBlockedPackage(id, packageName) {
3152
3175
  return id === packageName || id.startsWith(`${packageName}/`);
@@ -3196,10 +3219,10 @@ async function validateClientBuildOutput(root, srcDir, outputDir) {
3196
3219
  }
3197
3220
  }
3198
3221
  function getCachedClientModuleHydrationPlan(modulePath, root, mode, cache, options = {}) {
3199
- const key = _chunkQYDGIXQ5cjs.getClientModuleHydrationPlanKey.call(void 0, modulePath, root, mode, options);
3222
+ const key = _chunkU3A46QFDcjs.getClientModuleHydrationPlanKey.call(void 0, modulePath, root, mode, options);
3200
3223
  let plan = cache.get(key);
3201
3224
  if (!plan) {
3202
- plan = _chunkQYDGIXQ5cjs.getClientModuleHydrationPlan.call(void 0, modulePath, root, mode, options);
3225
+ plan = _chunkU3A46QFDcjs.getClientModuleHydrationPlan.call(void 0, modulePath, root, mode, options);
3203
3226
  cache.set(key, plan);
3204
3227
  }
3205
3228
  return { ...plan, isolatedBoundaries: [...plan.isolatedBoundaries] };
@@ -3213,7 +3236,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3213
3236
  farmPlugin,
3214
3237
  farmServerOnlyEntriesPlugin
3215
3238
  } = await import("./vite.cjs");
3216
- const { PluginManager: PluginManager2 } = await import("./plugin-3PT7I26P.cjs");
3239
+ const { PluginManager: PluginManager2 } = await import("./plugin-MWO3G2XM.cjs");
3217
3240
  const fs5 = await import("fs/promises");
3218
3241
  const pluginManager = new PluginManager2({
3219
3242
  config,
@@ -3228,44 +3251,44 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3228
3251
  const unsupportedIntegrationProvider = integrationProviders.find(
3229
3252
  (provider) => provider.supportsIsolatedHydration !== true
3230
3253
  );
3231
- if (_optionalChain([config, 'access', _99 => _99.experimental, 'optionalAccess', _100 => _100.isolatedClientHydration]) === "enabled" && _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _101 => _101.experimental, 'optionalAccess', _102 => _102.serverComponents])) !== "rsc" && unsupportedIntegrationProvider) {
3254
+ if (_optionalChain([config, 'access', _94 => _94.experimental, 'optionalAccess', _95 => _95.isolatedClientHydration]) === "enabled" && _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _96 => _96.experimental, 'optionalAccess', _97 => _97.serverComponents])) !== "rsc" && unsupportedIntegrationProvider) {
3232
3255
  _chunk7U4XF76Rcjs.logger.warn(
3233
3256
  `[Farm.js] isolated hydration kept route-wide because integration provider "${unsupportedIntegrationProvider.name}" does not declare supportsIsolatedHydration: true.`
3234
3257
  );
3235
3258
  }
3236
- const isolatedMode = _chunkQYDGIXQ5cjs.resolveFarmIsolatedClientHydrationMode.call(void 0,
3237
- _optionalChain([config, 'access', _103 => _103.experimental, 'optionalAccess', _104 => _104.isolatedClientHydration]),
3259
+ const isolatedMode = _chunkU3A46QFDcjs.resolveFarmIsolatedClientHydrationMode.call(void 0,
3260
+ _optionalChain([config, 'access', _98 => _98.experimental, 'optionalAccess', _99 => _99.isolatedClientHydration]),
3238
3261
  {
3239
- serverComponents: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _105 => _105.experimental, 'optionalAccess', _106 => _106.serverComponents])) === "rsc",
3262
+ serverComponents: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _100 => _100.experimental, 'optionalAccess', _101 => _101.serverComponents])) === "rsc",
3240
3263
  hasUnsupportedIntegrationProvider: Boolean(unsupportedIntegrationProvider)
3241
3264
  }
3242
3265
  );
3243
- const planOptions = _chunkQYDGIXQ5cjs.getFarmClientHydrationPlanOptions.call(void 0,
3266
+ const planOptions = _chunkU3A46QFDcjs.getFarmClientHydrationPlanOptions.call(void 0,
3244
3267
  config.renderer,
3245
3268
  Boolean(unsupportedIntegrationProvider)
3246
3269
  );
3247
3270
  const pagePlanOptions = {
3248
3271
  ...planOptions,
3249
- serverOwners: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _107 => _107.experimental, 'optionalAccess', _108 => _108.serverComponents])) === "islands"
3272
+ serverOwners: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _102 => _102.experimental, 'optionalAccess', _103 => _103.serverComponents])) === "islands"
3250
3273
  };
3251
3274
  const layoutPlanOptions = {
3252
3275
  ...planOptions,
3253
3276
  serverTreeLayouts: pagePlanOptions.serverOwners
3254
3277
  };
3255
- const layoutAppliesToRoute = _chunk4B6YJ5DScjs.routeBoundaryCoversDirectory;
3278
+ const layoutAppliesToRoute = _chunk4ZVKDHS6cjs.routeBoundaryCoversDirectory;
3256
3279
  const routeDirectory = (route) => _nullishCoalesce(route.directory, () => ( route.pattern));
3257
- const islandsMode = _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _109 => _109.experimental, 'optionalAccess', _110 => _110.serverComponents])) === "islands";
3280
+ const islandsMode = _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _104 => _104.experimental, 'optionalAccess', _105 => _105.serverComponents])) === "islands";
3258
3281
  const adapterOwnsDocsRuntime = _chunkL2GUEYHRcjs.hasFarmDocsRuntimeAdapter.call(void 0, config.docs);
3259
- const docsEntries = _optionalChain([config, 'access', _111 => _111.docs, 'optionalAccess', _112 => _112.enabled]) ? _chunkHR5GU4UUcjs.getFarmDocsRoots.call(void 0, config.docs).map(
3282
+ const docsEntries = _optionalChain([config, 'access', _106 => _106.docs, 'optionalAccess', _107 => _107.enabled]) ? _chunkHR5GU4UUcjs.getFarmDocsRoots.call(void 0, config.docs).map(
3260
3283
  (docsRoot) => `/${docsRoot.entry || "docs"}`.replace(/\/+/g, "/").replace(/\/$/, "") || "/"
3261
3284
  ) : [];
3262
3285
  const adapterDocsEntry = _nullishCoalesce(docsEntries[0], () => ( null));
3263
3286
  const isAdapterDocsRoute = (routePattern) => adapterOwnsDocsRuntime && docsEntries.some(
3264
3287
  (docsEntry) => docsEntry === "/" || routePattern === docsEntry || routePattern.startsWith(`${docsEntry}/`)
3265
3288
  );
3266
- const syntheticDocsEntry = _optionalChain([config, 'access', _113 => _113.docs, 'optionalAccess', _114 => _114.enabled]) && !adapterOwnsDocsRuntime ? adapterDocsEntry : null;
3289
+ const syntheticDocsEntry = _optionalChain([config, 'access', _108 => _108.docs, 'optionalAccess', _109 => _109.enabled]) && !adapterOwnsDocsRuntime ? adapterDocsEntry : null;
3267
3290
  const syntheticDocsPatterns = syntheticDocsEntry ? syntheticDocsEntry === "/" ? ["/", "/[...slug]"] : [syntheticDocsEntry, `${syntheticDocsEntry}/[...slug]`] : [];
3268
- const plan = (operation) => sourceSnapshot ? _chunkQYDGIXQ5cjs.withFarmSourceSnapshotOf.call(void 0, sourceSnapshot, operation) : _chunkQYDGIXQ5cjs.withFarmSourceSnapshot.call(void 0, operation);
3291
+ const plan = (operation) => sourceSnapshot ? _chunkU3A46QFDcjs.withFarmSourceSnapshotOf.call(void 0, sourceSnapshot, operation) : _chunkU3A46QFDcjs.withFarmSourceSnapshot.call(void 0, operation);
3269
3292
  const { clientLayouts, clientRouteSlots } = plan(() => {
3270
3293
  const clientLayouts2 = layoutRoutes.map((layout) => {
3271
3294
  try {
@@ -3312,7 +3335,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3312
3335
  };
3313
3336
  }
3314
3337
  });
3315
- const markdownPagePlan = _chunkQYDGIXQ5cjs.createMarkdownPageHydrationPlanner.call(void 0,
3338
+ const markdownPagePlan = _chunkU3A46QFDcjs.createMarkdownPageHydrationPlanner.call(void 0,
3316
3339
  _chunk2HW5LWAHcjs.resolveFarmMdxComponentsModulePath.call(void 0, _chunk2HW5LWAHcjs.resolveMdxConfig.call(void 0, config.mdx), root),
3317
3340
  root,
3318
3341
  isolatedMode,
@@ -3328,7 +3351,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3328
3351
  pagePlanOptions
3329
3352
  )
3330
3353
  }));
3331
- _chunkQYDGIXQ5cjs.enforceFarmIsolatedHydrationRouteBudget.call(void 0,
3354
+ _chunkU3A46QFDcjs.enforceFarmIsolatedHydrationRouteBudget.call(void 0,
3332
3355
  clientLayouts2.map((layout) => ({
3333
3356
  pattern: layout.pattern,
3334
3357
  depth: layout.pattern.split("/").filter(Boolean).length,
@@ -3337,7 +3360,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3337
3360
  [
3338
3361
  ...routePlans.map(({ route, metadata }) => ({
3339
3362
  pattern: routeDirectory(route),
3340
- depth: _chunk4B6YJ5DScjs.getRouteDirectoryDepth.call(void 0, routeDirectory(route)),
3363
+ depth: _chunk4ZVKDHS6cjs.getRouteDirectoryDepth.call(void 0, routeDirectory(route)),
3341
3364
  metadata
3342
3365
  })),
3343
3366
  ...syntheticDocsPatterns.map((pattern) => ({
@@ -3362,7 +3385,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3362
3385
  const matchesBuiltRoute = pageRoutes.some((route) => layoutAppliesToRoute(layout.pattern, routeDirectory(route))) || docsEntries.some((docsEntry) => layoutAppliesToRoute(layout.pattern, docsEntry));
3363
3386
  if (matchesBuiltRoute && layout.suppressedAsyncHydration) {
3364
3387
  _chunk7U4XF76Rcjs.logger.warn(
3365
- `\u26A0\uFE0F ${_chunkQYDGIXQ5cjs.describeSuppressedAsyncHydration.call(void 0, layout.pattern, layout.fallbackReason)}`
3388
+ `\u26A0\uFE0F ${_chunkU3A46QFDcjs.describeSuppressedAsyncHydration.call(void 0, layout.pattern, layout.fallbackReason)}`
3366
3389
  );
3367
3390
  }
3368
3391
  }
@@ -3397,7 +3420,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3397
3420
  );
3398
3421
  if (metadata.suppressedAsyncHydration) {
3399
3422
  _chunk7U4XF76Rcjs.logger.warn(
3400
- `\u26A0\uFE0F ${_chunkQYDGIXQ5cjs.describeSuppressedAsyncHydration.call(void 0, route.pattern, metadata.fallbackReason)}`
3423
+ `\u26A0\uFE0F ${_chunkU3A46QFDcjs.describeSuppressedAsyncHydration.call(void 0, route.pattern, metadata.fallbackReason)}`
3401
3424
  );
3402
3425
  }
3403
3426
  const slotBoundaries = serverSlotPlans.filter(
@@ -3405,7 +3428,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3405
3428
  ).flatMap(({ plan: plan2 }) => plan2.isolatedBoundaries);
3406
3429
  if (metadata.shouldHydrate || metadata.hasIsolatedClientBoundaries || applicableClientLayouts.length > 0 || slotBoundaries.length > 0) {
3407
3430
  const relativePath = route.modulePath.replace(root, "").replace(/^\//, "");
3408
- const islandStrategy = _chunkP253SZJFcjs.resolveFarmRouteRootStrategy.call(void 0,
3431
+ const islandStrategy = _chunkTI4BZV6Mcjs.resolveFarmRouteRootStrategy.call(void 0,
3409
3432
  route,
3410
3433
  metadata,
3411
3434
  clientLayouts2,
@@ -3424,7 +3447,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3424
3447
  ...applicableClientLayouts.filter((layout) => layout.hasIsolatedClientBoundaries || layout.serverTreeLayout).flatMap((layout) => layout.isolatedBoundaries)
3425
3448
  ],
3426
3449
  // The server renders a server tree only below a hydrating layout.
3427
- ..._chunkQYDGIXQ5cjs.usesFarmServerTree.call(void 0, metadata) && applicableClientLayouts.some((layout) => layout.shouldHydrate) ? { serverTree: true } : {}
3450
+ ..._chunkU3A46QFDcjs.usesFarmServerTree.call(void 0, metadata) && applicableClientLayouts.some((layout) => layout.shouldHydrate) ? { serverTree: true } : {}
3428
3451
  });
3429
3452
  _chunk7U4XF76Rcjs.logger.info(`\u{1F4F1} Found hydratable route: ${route.pattern} -> ${route.modulePath}`);
3430
3453
  }
@@ -3461,7 +3484,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3461
3484
  }
3462
3485
  const clientRouteSlots2 = routeSlots.filter((slot) => {
3463
3486
  try {
3464
- const metadata = _chunkQYDGIXQ5cjs.getClientModuleMetadata.call(void 0, slot.modulePath, root);
3487
+ const metadata = _chunkU3A46QFDcjs.getClientModuleMetadata.call(void 0, slot.modulePath, root);
3465
3488
  return metadata.shouldHydrate && (!islandsMode || metadata.isClientComponent);
3466
3489
  } catch (error) {
3467
3490
  _chunk7U4XF76Rcjs.logger.warn(`\u26A0\uFE0F Could not inspect route slot ${slot.modulePath}: ${error}`);
@@ -3505,7 +3528,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3505
3528
  srcDir,
3506
3529
  adapterOwnsDocsRuntime ? false : _chunkN3H7UPBMcjs.isFarmDocsSearchEnabled.call(void 0, config.docs),
3507
3530
  adapterOwnsDocsRuntime ? void 0 : _chunkN3H7UPBMcjs.resolveFarmDocsSearchClientModule.call(void 0, root),
3508
- _optionalChain([config, 'access', _115 => _115.docs, 'optionalAccess', _116 => _116.enabled]) ? _chunkHR5GU4UUcjs.getFarmDocsRoots.call(void 0, config.docs).map((docsRoot) => docsRoot.entry) : void 0,
3531
+ _optionalChain([config, 'access', _110 => _110.docs, 'optionalAccess', _111 => _111.enabled]) ? _chunkHR5GU4UUcjs.getFarmDocsRoots.call(void 0, config.docs).map((docsRoot) => docsRoot.entry) : void 0,
3509
3532
  adapterOwnsDocsRuntime ? _chunkL2GUEYHRcjs.getFarmDocsAdapterUIModule.call(void 0, config.docs.adapter) : void 0,
3510
3533
  config.i18n,
3511
3534
  config.plugins,
@@ -3514,11 +3537,11 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3514
3537
  config.trailingSlash,
3515
3538
  _chunkB3HQTGXScjs.getIntegrationProviders.call(void 0, config.integrations),
3516
3539
  config.basePath,
3517
- _chunkP253SZJFcjs.generateClientCachePersistenceCode.call(void 0, _chunkP253SZJFcjs.resolveFarmClientCacheAdapterEntry.call(void 0, root, config.cache)),
3540
+ _chunkTI4BZV6Mcjs.generateClientCachePersistenceCode.call(void 0, _chunkTI4BZV6Mcjs.resolveFarmClientCacheAdapterEntry.call(void 0, root, config.cache)),
3518
3541
  adapterOwnsDocsRuntime ? _chunkXJDB564Acjs.getFarmDocsAdapterConfigModule.call(void 0, config.docs) : void 0,
3519
- _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _117 => _117.experimental, 'optionalAccess', _118 => _118.serverComponents])) === "islands",
3542
+ _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _112 => _112.experimental, 'optionalAccess', _113 => _113.serverComponents])) === "islands",
3520
3543
  platform,
3521
- islandsMode ? _chunkQYDGIXQ5cjs.collectFarmServerStylesheets.call(void 0,
3544
+ islandsMode ? _chunkU3A46QFDcjs.collectFarmServerStylesheets.call(void 0,
3522
3545
  [
3523
3546
  ...layoutRoutes.map((layout) => layout.modulePath),
3524
3547
  ...pageRoutes.filter((route) => !isAdapterDocsRoute(route.pattern)).map((route) => route.modulePath)
@@ -3542,7 +3565,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3542
3565
  await fs5.writeFile(_path2.default.join(clientEntryDir, "farm-client-root.tsx"), clientEntry.root);
3543
3566
  }
3544
3567
  const clientInput = { [entryName]: clientEntryPath };
3545
- if (platform === "web" && _chunkP253SZJFcjs.canBootFarmIslandsClient.call(void 0, config)) {
3568
+ if (platform === "web" && _chunkTI4BZV6Mcjs.canBootFarmIslandsClient.call(void 0, config)) {
3546
3569
  const clientBootPath = _path2.default.join(clientEntryDir, "farm-client-boot.tsx");
3547
3570
  await fs5.writeFile(
3548
3571
  clientBootPath,
@@ -3584,11 +3607,11 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3584
3607
  target: FARM_CLIENT_BUILD_TARGET,
3585
3608
  // Tailwind CSS 4 already requires newer browsers than that baseline. An app's own
3586
3609
  // `build.target` or `build.cssTarget` still decides, as Vite derives one from the other.
3587
- ..._optionalChain([config, 'access', _119 => _119.vite, 'optionalAccess', _120 => _120.build, 'optionalAccess', _121 => _121.target]) === void 0 && _optionalChain([config, 'access', _122 => _122.vite, 'optionalAccess', _123 => _123.build, 'optionalAccess', _124 => _124.cssTarget]) === void 0 && (_chunkDMSXZNQRcjs.includesTailwindVitePlugin.call(void 0, tailwindVitePlugin) || _chunkDMSXZNQRcjs.includesTailwindVitePlugin.call(void 0, _optionalChain([config, 'access', _125 => _125.vite, 'optionalAccess', _126 => _126.plugins]))) ? { cssTarget: _chunkDMSXZNQRcjs.TAILWIND_CSS_BROWSER_TARGET } : {},
3610
+ ..._optionalChain([config, 'access', _114 => _114.vite, 'optionalAccess', _115 => _115.build, 'optionalAccess', _116 => _116.target]) === void 0 && _optionalChain([config, 'access', _117 => _117.vite, 'optionalAccess', _118 => _118.build, 'optionalAccess', _119 => _119.cssTarget]) === void 0 && (_chunkDMSXZNQRcjs.includesTailwindVitePlugin.call(void 0, tailwindVitePlugin) || _chunkDMSXZNQRcjs.includesTailwindVitePlugin.call(void 0, _optionalChain([config, 'access', _120 => _120.vite, 'optionalAccess', _121 => _121.plugins]))) ? { cssTarget: _chunkDMSXZNQRcjs.TAILWIND_CSS_BROWSER_TARGET } : {},
3588
3611
  outDir: outputDir,
3589
3612
  emptyOutDir: platform === "web",
3590
3613
  // Never public: see resolveFarmClientSourcemap.
3591
- sourcemap: resolveFarmClientSourcemap(_optionalChain([config, 'access', _127 => _127.vite, 'optionalAccess', _128 => _128.build, 'optionalAccess', _129 => _129.sourcemap])),
3614
+ sourcemap: resolveFarmClientSourcemap(_optionalChain([config, 'access', _122 => _122.vite, 'optionalAccess', _123 => _123.build, 'optionalAccess', _124 => _124.sourcemap])),
3592
3615
  assetsInlineLimit: 0,
3593
3616
  cssCodeSplit: false,
3594
3617
  // Bundle all CSS into one file
@@ -3598,10 +3621,9 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3598
3621
  entryFileNames: "[name]-h[hash].js",
3599
3622
  chunkFileNames: "chunks/[name]-h[hash].js",
3600
3623
  hashCharacters: "hex",
3601
- ...islandsMode && _chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) && !configuresFarmClientChunks(config.vite) ? { codeSplitting: { groups: [createFarmIslandsReactChunkGroup()] } } : {},
3602
3624
  // Use predictable name for CSS so we can reference it in SSR HTML
3603
3625
  assetFileNames: (assetInfo) => {
3604
- if (_optionalChain([assetInfo, 'access', _130 => _130.name, 'optionalAccess', _131 => _131.endsWith, 'call', _132 => _132(".css")])) {
3626
+ if (_optionalChain([assetInfo, 'access', _125 => _125.name, 'optionalAccess', _126 => _126.endsWith, 'call', _127 => _127(".css")])) {
3605
3627
  return `${entryName}.css`;
3606
3628
  }
3607
3629
  return "assets/[name]-h[hash][extname]";
@@ -3618,7 +3640,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3618
3640
  }
3619
3641
  },
3620
3642
  plugins: [
3621
- _chunkP253SZJFcjs.createFarmThemeCssPlugin.call(void 0, config.theme, config.basePath),
3643
+ _chunkTI4BZV6Mcjs.createFarmThemeCssPlugin.call(void 0, config.theme, config.basePath),
3622
3644
  createFarmPrivateClientSourcemapsPlugin({
3623
3645
  outDir: _path2.default.join(
3624
3646
  _path2.default.dirname(outputDir),
@@ -3668,9 +3690,11 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3668
3690
  ...tailwindVitePlugin ? [tailwindVitePlugin] : [],
3669
3691
  ...rendererVitePlugins,
3670
3692
  ...config.vite.plugins || [],
3693
+ // React in one chunk, unless the app's config or one of its plugins splits chunks.
3694
+ ...islandsMode && _chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) ? [createFarmIslandsReactChunkPlugin()] : [],
3671
3695
  farmServerOnlyEntriesPlugin({ platform, distDir: config.distDir || ".farm" }),
3672
3696
  farmNavigationPlugin(config.renderer),
3673
- _chunkP253SZJFcjs.farmDocsClientConfigPlugin.call(void 0,
3697
+ _chunkTI4BZV6Mcjs.farmDocsClientConfigPlugin.call(void 0,
3674
3698
  adapterOwnsDocsRuntime ? _chunkXJDB564Acjs.getFarmDocsAdapterConfigModule.call(void 0, config.docs) : void 0
3675
3699
  ),
3676
3700
  // Plugin to redirect @farm.js/core imports to client-only exports
@@ -3703,7 +3727,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3703
3727
  },
3704
3728
  load: {
3705
3729
  filter: {
3706
- id: _chunkP253SZJFcjs.exactIdPattern.call(void 0, [
3730
+ id: _chunkTI4BZV6Mcjs.exactIdPattern.call(void 0, [
3707
3731
  "\0empty-module",
3708
3732
  "\0empty-api-route",
3709
3733
  "\0farm-i18n-client-bridge",
@@ -3741,7 +3765,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3741
3765
  { ...config, isolatedClientBoundaryModules, programmaticClientRoutes, sourceSnapshot },
3742
3766
  pluginManager
3743
3767
  ),
3744
- _chunkQYDGIXQ5cjs.farmEnvironmentFunctionsPlugin.call(void 0, config)
3768
+ _chunkU3A46QFDcjs.farmEnvironmentFunctionsPlugin.call(void 0, config)
3745
3769
  ],
3746
3770
  mode: "production",
3747
3771
  css: postcssSearchPath ? {
@@ -3749,7 +3773,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3749
3773
  } : void 0,
3750
3774
  // Ensure React is bundled for client
3751
3775
  resolve: {
3752
- alias: _chunkP253SZJFcjs.createFarmSourceAlias.call(void 0, root, config.srcDir),
3776
+ alias: _chunkTI4BZV6Mcjs.createFarmSourceAlias.call(void 0, root, config.srcDir),
3753
3777
  dedupe: [...config.renderer.dedupe || []]
3754
3778
  },
3755
3779
  // Optimize dependencies - exclude server-side code from client bundle
@@ -3763,7 +3787,7 @@ async function buildClient(productionVite, config, root, srcDir, outputDir, page
3763
3787
  }
3764
3788
  };
3765
3789
  await viteBuild(
3766
- _chunkP253SZJFcjs.mergeFarmProductionViteConfig.call(void 0, clientViteConfig, config.vite, { clientOutput: true })
3790
+ _chunkTI4BZV6Mcjs.mergeFarmProductionViteConfig.call(void 0, clientViteConfig, config.vite, { clientOutput: true })
3767
3791
  );
3768
3792
  if (platform === "mobile") {
3769
3793
  await fs5.rm(_path2.default.join(outputDir, `${entryName}.css`), { force: true });
@@ -3857,9 +3881,9 @@ async function fetchFarmNavigationDocument(url, headers, recover = true, signal)
3857
3881
  return response;
3858
3882
  }
3859
3883
 
3860
- ${streamNavigations ? `${_chunkP253SZJFcjs.FARM_NAVIGATION_STREAM_READER_SOURCE}
3884
+ ${streamNavigations ? `${_chunkTI4BZV6Mcjs.FARM_NAVIGATION_STREAM_READER_SOURCE}
3861
3885
 
3862
- ${_chunkP253SZJFcjs.FARM_EARLY_NAVIGATION_SOURCE}` : ""}
3886
+ ${_chunkTI4BZV6Mcjs.FARM_EARLY_NAVIGATION_SOURCE}` : ""}
3863
3887
 
3864
3888
  function clearFarmPrefetchCacheOnDeploymentMismatch(router, error) {
3865
3889
  if (error?.name === "FarmDeploymentMismatchError") {
@@ -4028,8 +4052,8 @@ for (const type of FARM_ROUTE_TABLE_INTENT_EVENTS) {
4028
4052
  }`;
4029
4053
  }
4030
4054
  function getFarmClientLayoutMatch(pattern) {
4031
- const groupScope = _chunk4B6YJ5DScjs.getRouteGroupScope.call(void 0, pattern);
4032
- return groupScope ? { pattern, urlPattern: _chunk4B6YJ5DScjs.stripRouteGroups.call(void 0, pattern), groupScope } : { pattern };
4055
+ const groupScope = _chunk4ZVKDHS6cjs.getRouteGroupScope.call(void 0, pattern);
4056
+ return groupScope ? { pattern, urlPattern: _chunk4ZVKDHS6cjs.stripRouteGroups.call(void 0, pattern), groupScope } : { pattern };
4033
4057
  }
4034
4058
  function generateFarmClientLayoutSelectionSource() {
4035
4059
  return `function selectFarmClientLayouts(layouts, routePathname, readDirectory) {
@@ -5032,7 +5056,7 @@ function readFarmEntryImports(source) {
5032
5056
  for (const match of source.matchAll(/^import\s+([^"';]+?)\s+from\s+(["'][^"']+["'])/gm)) {
5033
5057
  const from = match[2];
5034
5058
  const named = /\{([^}]*)\}/.exec(match[1]);
5035
- for (const specifier of _nullishCoalesce(_optionalChain([named, 'optionalAccess', _133 => _133[1], 'optionalAccess', _134 => _134.split, 'call', _135 => _135(",")]), () => ( []))) {
5059
+ for (const specifier of _nullishCoalesce(_optionalChain([named, 'optionalAccess', _128 => _128[1], 'optionalAccess', _129 => _129.split, 'call', _130 => _130(",")]), () => ( []))) {
5036
5060
  const [imported, local] = specifier.trim().split(/\s+as\s+/);
5037
5061
  if (imported)
5038
5062
  bindings.push({ local: _nullishCoalesce(local, () => ( imported)), clause: `{ ${specifier.trim()} }`, from });
@@ -5194,7 +5218,7 @@ import { createRoot, hydrateRoot } from ${JSON.stringify(renderer.client)};
5194
5218
  const React = { ...__farmRendererClient };`
5195
5219
  );
5196
5220
  const hydrateFarmRouteCall = _chunkT7UC2ORAcjs.isReactRenderer.call(void 0, renderer) ? "return hydrateRoot(container, route.element);" : "return route.layouts.length > 0 ? hydrateRoot(container, route.element, route) : hydrateRoot(container, route.element);";
5197
- const providerClientCode = _chunkP253SZJFcjs.generateFarmIntegrationProviderClientCode.call(void 0,
5221
+ const providerClientCode = _chunkTI4BZV6Mcjs.generateFarmIntegrationProviderClientCode.call(void 0,
5198
5222
  integrationProviders,
5199
5223
  root,
5200
5224
  _nullishCoalesce(renderer.componentExtensions, () => ( []))
@@ -5218,12 +5242,12 @@ const React = { ...__farmRendererClient };`
5218
5242
  const layoutRegistrations = [];
5219
5243
  const layoutComponents = [];
5220
5244
  const hydratingLayoutPatterns = layoutRoutes.filter((layout) => layout.shouldHydrate).map((layout) => layout.pattern);
5221
- const treeLayoutPatterns = islandValues ? _chunk4B6YJ5DScjs.getFarmServerTreeLayoutPatterns.call(void 0, layoutRoutes) : /* @__PURE__ */ new Set();
5245
+ const treeLayoutPatterns = islandValues ? _chunk4ZVKDHS6cjs.getFarmServerTreeLayoutPatterns.call(void 0, layoutRoutes) : /* @__PURE__ */ new Set();
5222
5246
  layoutRoutes.forEach((layout, index) => {
5223
5247
  const relativePath = toImportPath(layout.modulePath);
5224
5248
  const treeLayout = treeLayoutPatterns.has(layout.pattern);
5225
5249
  const rendersOnClient = treeLayout || !layout.hasIsolatedClientBoundaries && hydratingLayoutPatterns.some(
5226
- (pattern) => _chunk4B6YJ5DScjs.layoutsCanCoverSamePage.call(void 0, layout.pattern, pattern)
5250
+ (pattern) => _chunk4ZVKDHS6cjs.layoutsCanCoverSamePage.call(void 0, layout.pattern, pattern)
5227
5251
  );
5228
5252
  if (rendersOnClient && !treeLayout) {
5229
5253
  layoutImportStatements.push(`import Layout${index} from "${relativePath}";`);
@@ -5328,7 +5352,7 @@ mountFarmDocsSearch();
5328
5352
 
5329
5353
  ${generateUniversalRouterStateRuntime()}
5330
5354
 
5331
- ${_chunkP253SZJFcjs.FARM_NAVIGATION_SCRIPT_SOURCE}
5355
+ ${_chunkTI4BZV6Mcjs.FARM_NAVIGATION_SCRIPT_SOURCE}
5332
5356
 
5333
5357
  // SPA Router for server-rendered pages (HTML swap)
5334
5358
  const spaRouter = {
@@ -5647,8 +5671,9 @@ let hydrateRoot;
5647
5671
  let farmRendererLoading = null;
5648
5672
  let farmRendererLoaded = false;${isolatedHydrationEnabled ? `
5649
5673
  // The boot stops holding interactions once this entry runs. Until islx loads, islands that have not
5650
- // hydrated hold them here, for their schedulers to replay.
5651
- const releaseFarmIslandInteractions = holdFarmIslandInteractions("f-island");` : ""}
5674
+ // hydrated hold them here, for their schedulers to replay, and a server component's form waits for
5675
+ // islx to post it without a page load.
5676
+ const releaseFarmIslandInteractions = holdFarmIslandInteractions("f-island", loadFarmRenderer);` : ""}
5652
5677
  function loadFarmRenderer() {
5653
5678
  return farmRendererLoading || (farmRendererLoading = Promise.all([
5654
5679
  import("react"),
@@ -5868,7 +5893,7 @@ ${layoutRegistrations.join(",\n")}
5868
5893
  ${generateFarmClientRouteMatchSource({ lazyMatcher })}
5869
5894
 
5870
5895
  ${layoutComponentsRuntime}/*farm-root-start*/
5871
- ${_chunkP253SZJFcjs.FARM_LAYOUT_ELEMENT_CLIENT_SOURCE}
5896
+ ${_chunkTI4BZV6Mcjs.FARM_LAYOUT_ELEMENT_CLIENT_SOURCE}
5872
5897
  // Wrap a page element with applicable layouts
5873
5898
  function wrapWithLayouts(pageElement, pathname, params) {
5874
5899
  const layouts = getApplicableLayouts(pathname);
@@ -5903,7 +5928,7 @@ function createLayoutPageBoundary(route, pageElement, serverHtml) {
5903
5928
  return React.createElement("div", props, pageElement);
5904
5929
  }
5905
5930
  let farmLastRouteState = null;
5906
- ${hasServerTreeLayouts && islandValues && isolatedHydrationEnabled ? `${_chunkP253SZJFcjs.FARM_SERVER_TREE_LAYOUT_CLIENT_SOURCE}
5931
+ ${hasServerTreeLayouts && islandValues && isolatedHydrationEnabled ? `${_chunkTI4BZV6Mcjs.FARM_SERVER_TREE_LAYOUT_CLIENT_SOURCE}
5907
5932
  function farmTreeLayoutsOf(pathname) {
5908
5933
  return getApplicableLayouts(pathname).filter(function(layout) {
5909
5934
  return layout.serverTree === true;
@@ -6537,7 +6562,7 @@ function fitsSegmentResponse(currentRoot, nextRoot) {
6537
6562
  return true;
6538
6563
  }` : ""}
6539
6564
 
6540
- ${_chunkP253SZJFcjs.FARM_NAVIGATION_SCRIPT_SOURCE}
6565
+ ${_chunkTI4BZV6Mcjs.FARM_NAVIGATION_SCRIPT_SOURCE}
6541
6566
 
6542
6567
  function activateNavigationScripts(root) {
6543
6568
  for (const script of Array.from(root?.querySelectorAll?.("script") || [])) {
@@ -6643,7 +6668,7 @@ function getLayoutShell(root, patterns, index) {
6643
6668
  return shell.innerHTML;
6644
6669
  }
6645
6670
 
6646
- ${islandValues ? _chunkP253SZJFcjs.FARM_REFRESH_FIELDS_SOURCE : ""}function replaceSharedLayoutBoundary(currentRoot, nextRoot, refresh = false) {
6671
+ ${islandValues ? _chunkTI4BZV6Mcjs.FARM_REFRESH_FIELDS_SOURCE : ""}function replaceSharedLayoutBoundary(currentRoot, nextRoot, refresh = false) {
6647
6672
  // A refresh keeps the islands still on the page: the ones in streamed Suspense content too.
6648
6673
  if (refresh) revealFarmStreamedContent(nextRoot);
6649
6674
  const currentPatterns = getLayoutPatterns(currentRoot);
@@ -7322,7 +7347,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7322
7347
  farmPlugin,
7323
7348
  farmServerOnlyEntriesPlugin
7324
7349
  } = await import("./vite.cjs");
7325
- const { PluginManager: PluginManager2 } = await import("./plugin-3PT7I26P.cjs");
7350
+ const { PluginManager: PluginManager2 } = await import("./plugin-MWO3G2XM.cjs");
7326
7351
  const fs5 = await import("fs/promises");
7327
7352
  const pluginManager = new PluginManager2({
7328
7353
  config,
@@ -7450,7 +7475,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7450
7475
  }))
7451
7476
  );
7452
7477
  const instrumentationPath = _chunk3BTN3NP7cjs.resolveFarmInstrumentationFile.call(void 0, root, config.srcDir || "src");
7453
- const notFoundPath = _chunkP253SZJFcjs.resolveFarmNotFoundComponentPath.call(void 0,
7478
+ const notFoundPath = _chunkTI4BZV6Mcjs.resolveFarmNotFoundComponentPath.call(void 0,
7454
7479
  config,
7455
7480
  appDirs,
7456
7481
  routeManager.getRendererNotFoundPath()
@@ -7475,9 +7500,9 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7475
7500
  (provider) => provider.component || provider.type === "clerk"
7476
7501
  );
7477
7502
  const hasObservabilityHandler = !!config.observability && typeof config.observability === "object" && "onEvent" in config.observability;
7478
- const hasMdxComponentConfig = Boolean(_optionalChain([config, 'access', _136 => _136.mdx, 'optionalAccess', _137 => _137.components]));
7479
- const hasMiddlewareConfig = _chunk4B6YJ5DScjs.hasFarmMiddlewareConfig.call(void 0, config.middleware);
7480
- const hasRouteContextConfig = _chunkFDU4Q4QPcjs.hasCustomFarmRouteContext.call(void 0, config);
7503
+ const hasMdxComponentConfig = Boolean(_optionalChain([config, 'access', _131 => _131.mdx, 'optionalAccess', _132 => _132.components]));
7504
+ const hasMiddlewareConfig = _chunk4ZVKDHS6cjs.hasFarmMiddlewareConfig.call(void 0, config.middleware);
7505
+ const hasRouteContextConfig = _chunkMZR22RACcjs.hasCustomFarmRouteContext.call(void 0, config);
7481
7506
  const hasServerRuntimePlugins = _chunkDMSXZNQRcjs.hasFarmServerRuntimePlugins.call(void 0, config.plugins);
7482
7507
  const hasPluginRoutes = hasFarmPluginRoutes(config);
7483
7508
  const hasServerCacheConfig = hasFarmServerCacheConfig(config.cache);
@@ -7489,7 +7514,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7489
7514
  );
7490
7515
  if (_chunkL2GUEYHRcjs.hasFarmDocsRuntimeAdapter.call(void 0, config.docs)) {
7491
7516
  const adapterGuardedPaths = new Set(getFarmDocsGuardedPaths(config, middlewareRoutes));
7492
- _chunkBLZCAFGJcjs.assertFarmDocsAdapterServesNoGuardedPages.call(void 0,
7517
+ _chunkCXHVRHM2cjs.assertFarmDocsAdapterServesNoGuardedPages.call(void 0,
7493
7518
  config.docs,
7494
7519
  { root, srcDir: config.srcDir },
7495
7520
  (pathname) => adapterGuardedPaths.has(pathname),
@@ -7497,9 +7522,9 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7497
7522
  );
7498
7523
  }
7499
7524
  const farmDocsCspNonceMarker = _chunk6JHZPB52cjs.createFarmCspNonce.call(void 0, config.security);
7500
- const farmDocsPrecompiledManifest = _optionalChain([config, 'access', _138 => _138.docs, 'optionalAccess', _139 => _139.enabled]) && _chunkNLBHLPEOcjs.getFarmPresetRuntime.call(void 0, preset) === "edge" ? await _chunk2RSVYJT6cjs._runWithFarmCspNonce.call(void 0,
7525
+ const farmDocsPrecompiledManifest = _optionalChain([config, 'access', _133 => _133.docs, 'optionalAccess', _134 => _134.enabled]) && _chunkNLBHLPEOcjs.getFarmPresetRuntime.call(void 0, preset) === "edge" ? await _chunk2RSVYJT6cjs._runWithFarmCspNonce.call(void 0,
7501
7526
  farmDocsCspNonceMarker,
7502
- async () => _optionalChain([config, 'access', _140 => _140.docs, 'access', _141 => _141.adapter, 'optionalAccess', _142 => _142.server]) ? await _chunkBLZCAFGJcjs.compileFarmDocsAdapterEdgeManifest.call(void 0, config.docs, {
7527
+ async () => _optionalChain([config, 'access', _135 => _135.docs, 'access', _136 => _136.adapter, 'optionalAccess', _137 => _137.server]) ? await _chunkCXHVRHM2cjs.compileFarmDocsAdapterEdgeManifest.call(void 0, config.docs, {
7503
7528
  root,
7504
7529
  srcDir: config.srcDir,
7505
7530
  clientEntry: FARM_CLIENT_JS_SRC_PLACEHOLDER,
@@ -7613,7 +7638,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7613
7638
  // Adapters can render provider scripts by serializing function source.
7614
7639
  // keepNames injects helper calls into those functions; after Nitro
7615
7640
  // minifies the server chunk the helper is no longer in script scope.
7616
- keepNames: !(_optionalChain([config, 'access', _143 => _143.docs, 'optionalAccess', _144 => _144.enabled]) && _optionalChain([config, 'access', _145 => _145.docs, 'access', _146 => _146.adapter, 'optionalAccess', _147 => _147.server])),
7641
+ keepNames: !(_optionalChain([config, 'access', _138 => _138.docs, 'optionalAccess', _139 => _139.enabled]) && _optionalChain([config, 'access', _140 => _140.docs, 'access', _141 => _141.adapter, 'optionalAccess', _142 => _142.server])),
7617
7642
  jsxDev: false
7618
7643
  },
7619
7644
  // SSR configuration to externalize problematic modules
@@ -7663,10 +7688,10 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7663
7688
  define: {
7664
7689
  __FARM_API_BASE_URL__: JSON.stringify(config.api.baseURL),
7665
7690
  __FARM_ENV__: JSON.stringify(_chunk3EIPOTZVcjs.createBundledEnv.call(void 0, config.env)),
7666
- __FARM_PUBLIC_ENV__: JSON.stringify(_optionalChain([config, 'access', _148 => _148.env, 'optionalAccess', _149 => _149.public]) || {})
7691
+ __FARM_PUBLIC_ENV__: JSON.stringify(_optionalChain([config, 'access', _143 => _143.env, 'optionalAccess', _144 => _144.public]) || {})
7667
7692
  },
7668
7693
  plugins: [
7669
- _chunkP253SZJFcjs.createFarmThemeCssPlugin.call(void 0, config.theme, config.basePath),
7694
+ _chunkTI4BZV6Mcjs.createFarmThemeCssPlugin.call(void 0, config.theme, config.basePath),
7670
7695
  ...tailwindVitePlugin ? [tailwindVitePlugin] : [],
7671
7696
  ...rendererVitePlugins,
7672
7697
  ...config.vite.plugins || [],
@@ -7698,7 +7723,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7698
7723
  },
7699
7724
  pluginManager
7700
7725
  ),
7701
- _chunkQYDGIXQ5cjs.farmEnvironmentFunctionsPlugin.call(void 0, config),
7726
+ _chunkU3A46QFDcjs.farmEnvironmentFunctionsPlugin.call(void 0, config),
7702
7727
  ...hasRuntimeConfigModule ? [
7703
7728
  farmStripPlatformConfigPlugin(
7704
7729
  [
@@ -7710,7 +7735,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7710
7735
  {
7711
7736
  name: "farm-virtual-ssr-entry",
7712
7737
  resolveId: {
7713
- filter: { id: _chunkP253SZJFcjs.exactIdPattern.call(void 0, [virtualEntryId, "\0virtual:farm-ssr-entry"]) },
7738
+ filter: { id: _chunkTI4BZV6Mcjs.exactIdPattern.call(void 0, [virtualEntryId, "\0virtual:farm-ssr-entry"]) },
7714
7739
  handler(id) {
7715
7740
  if (id === virtualEntryId || id === "\0virtual:farm-ssr-entry") {
7716
7741
  return virtualEntryId;
@@ -7719,7 +7744,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7719
7744
  }
7720
7745
  },
7721
7746
  load: {
7722
- filter: { id: _chunkP253SZJFcjs.exactIdPattern.call(void 0, [virtualEntryId]) },
7747
+ filter: { id: _chunkTI4BZV6Mcjs.exactIdPattern.call(void 0, [virtualEntryId]) },
7723
7748
  handler(id) {
7724
7749
  if (id === virtualEntryId) {
7725
7750
  return virtualEntryCode;
@@ -7751,7 +7776,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7751
7776
  resolve: {
7752
7777
  alias: [
7753
7778
  ...shouldAliasReactServerToWebBuild(config.renderer, preset) ? [createFarmReactWebServerAlias(hasReactDomEdgeServerBuild(root))] : [],
7754
- ...Object.entries(_chunkP253SZJFcjs.createFarmSourceAlias.call(void 0, root, config.srcDir)).map(
7779
+ ...Object.entries(_chunkTI4BZV6Mcjs.createFarmSourceAlias.call(void 0, root, config.srcDir)).map(
7755
7780
  ([find, replacement]) => ({ find, replacement })
7756
7781
  )
7757
7782
  ],
@@ -7759,7 +7784,7 @@ async function buildSSRInMemory(productionVite, config, root, routeManager, apiR
7759
7784
  dedupe: [...config.renderer.dedupe || []]
7760
7785
  }
7761
7786
  };
7762
- await viteBuild(_chunkP253SZJFcjs.mergeFarmProductionViteConfig.call(void 0, serverViteConfig, config.vite));
7787
+ await viteBuild(_chunkTI4BZV6Mcjs.mergeFarmProductionViteConfig.call(void 0, serverViteConfig, config.vite));
7763
7788
  } finally {
7764
7789
  if (postcssConfigDir) {
7765
7790
  try {
@@ -7795,7 +7820,7 @@ function readFarmPageLastModified(pageRoutes) {
7795
7820
  return lastModified;
7796
7821
  }
7797
7822
  function getFarmDocsGuardedPaths(config, middlewareRoutes) {
7798
- if (!_optionalChain([config, 'access', _150 => _150.docs, 'optionalAccess', _151 => _151.enabled])) return [];
7823
+ if (!_optionalChain([config, 'access', _145 => _145.docs, 'optionalAccess', _146 => _146.enabled])) return [];
7799
7824
  const options = { root: config.root, srcDir: config.srcDir };
7800
7825
  const guards = {
7801
7826
  config: { middleware: config.middleware, integrations: config.integrations },
@@ -7803,18 +7828,18 @@ function getFarmDocsGuardedPaths(config, middlewareRoutes) {
7803
7828
  };
7804
7829
  return _chunkHR5GU4UUcjs.getFarmDocsRoots.call(void 0, config.docs).flatMap(
7805
7830
  (docsRoot) => _chunkHR5GU4UUcjs.discoverFarmDocsPages.call(void 0, _chunkHR5GU4UUcjs.resolveFarmDocsContentDir.call(void 0, docsRoot, options), docsRoot)
7806
- ).flatMap((page) => [page.href, _chunkHR5GU4UUcjs.getFarmDocsMarkdownPath.call(void 0, page.href)]).filter((pathname) => _chunk4B6YJ5DScjs.farmPathGuardCoversPage.call(void 0, guards, pathname));
7831
+ ).flatMap((page) => [page.href, _chunkHR5GU4UUcjs.getFarmDocsMarkdownPath.call(void 0, page.href)]).filter((pathname) => _chunk4ZVKDHS6cjs.farmPathGuardCoversPage.call(void 0, guards, pathname));
7807
7832
  }
7808
7833
  function getFarmAppOwnedDocsEnginePaths(agent, applicationMetadataRoutes) {
7809
- const llmsTxt = _optionalChain([agent, 'optionalAccess', _152 => _152.llmsTxt]);
7834
+ const llmsTxt = _optionalChain([agent, 'optionalAccess', _147 => _147.llmsTxt]);
7810
7835
  const ownedByFile = (kind) => applicationMetadataRoutes.some(
7811
7836
  (metadata) => metadata.kind === kind && metadata.pattern === "/"
7812
7837
  );
7813
7838
  return [
7814
- ..._optionalChain([llmsTxt, 'optionalAccess', _153 => _153.enabled]) || ownedByFile("llms") ? ["/llms.txt"] : [],
7815
- ..._optionalChain([llmsTxt, 'optionalAccess', _154 => _154.enabled]) && llmsTxt.full || ownedByFile("llms-full") ? ["/llms-full.txt"] : [],
7816
- ..._optionalChain([agent, 'optionalAccess', _155 => _155.sitemap, 'optionalAccess', _156 => _156.enabled]) || ownedByFile("sitemap") ? ["/sitemap.xml"] : [],
7817
- ..._optionalChain([agent, 'optionalAccess', _157 => _157.crawlers, 'optionalAccess', _158 => _158.enabled]) || ownedByFile("robots") ? ["/robots.txt"] : []
7839
+ ..._optionalChain([llmsTxt, 'optionalAccess', _148 => _148.enabled]) || ownedByFile("llms") ? ["/llms.txt"] : [],
7840
+ ..._optionalChain([llmsTxt, 'optionalAccess', _149 => _149.enabled]) && llmsTxt.full || ownedByFile("llms-full") ? ["/llms-full.txt"] : [],
7841
+ ..._optionalChain([agent, 'optionalAccess', _150 => _150.sitemap, 'optionalAccess', _151 => _151.enabled]) || ownedByFile("sitemap") ? ["/sitemap.xml"] : [],
7842
+ ..._optionalChain([agent, 'optionalAccess', _152 => _152.crawlers, 'optionalAccess', _153 => _153.enabled]) || ownedByFile("robots") ? ["/robots.txt"] : []
7818
7843
  ];
7819
7844
  }
7820
7845
  function generateFarmDocsAdapterHandlerArguments(docs, docsConfigModulePath) {
@@ -7825,7 +7850,7 @@ function generateFarmDocsAdapterHandlerArguments(docs, docsConfigModulePath) {
7825
7850
  docsPath: ${root}.entry,
7826
7851
  contentDir: ${root}.contentDir || ${root}.config?.contentDir,
7827
7852
  }`;
7828
- if (_optionalChain([docs, 'optionalAccess', _159 => _159.roots, 'optionalAccess', _160 => _160.length])) {
7853
+ if (_optionalChain([docs, 'optionalAccess', _154 => _154.roots, 'optionalAccess', _155 => _155.length])) {
7829
7854
  return {
7830
7855
  factory: "createFarmDocsAdapterMultiRuntimeHandler",
7831
7856
  config: `[farmDocsResolvedConfig, ...farmDocsResolvedConfig.roots].map((farmDocsRoot) => (${runtimeConfig("farmDocsRoot")}))`
@@ -7838,7 +7863,7 @@ function generateFarmDocsAdapterHandlerArguments(docs, docsConfigModulePath) {
7838
7863
  }
7839
7864
  function generateFarmDocsRuntimeConfigExpression(docs, precompiled = false) {
7840
7865
  if (!docs.enabled) return "null";
7841
- const serializableDocs = _optionalChain([docs, 'access', _161 => _161.roots, 'optionalAccess', _162 => _162.length]) ? {
7866
+ const serializableDocs = _optionalChain([docs, 'access', _156 => _156.roots, 'optionalAccess', _157 => _157.length]) ? {
7842
7867
  ...docs,
7843
7868
  // React elements and functions do not survive JSON; see runtimeConfig below.
7844
7869
  roots: docs.roots.map((docsRoot) => ({ ...docsRoot, runtimeConfig: void 0 }))
@@ -7872,7 +7897,7 @@ function generateFarmDocsRuntimeConfigExpression(docs, precompiled = false) {
7872
7897
  },
7873
7898
  }
7874
7899
  : ${JSON.stringify({ ...serializableDocs, runtimeConfig: void 0 })}`;
7875
- if (!_optionalChain([docs, 'access', _163 => _163.roots, 'optionalAccess', _164 => _164.length])) return expression;
7900
+ if (!_optionalChain([docs, 'access', _158 => _158.roots, 'optionalAccess', _159 => _159.length])) return expression;
7876
7901
  return `((farmDocs) => ({
7877
7902
  ...farmDocs,
7878
7903
  roots: farmDocs.roots.map((farmDocsRoot, index) => {
@@ -7889,7 +7914,7 @@ function toVirtualEntryImportSpecifier(modulePath) {
7889
7914
  return JSON.stringify(modulePath.replace(/\\/g, "/"));
7890
7915
  }
7891
7916
  function generateNativeAuthIntegrationSource(auth) {
7892
- if (_optionalChain([auth, 'optionalAccess', _165 => _165.enabled]) !== true) {
7917
+ if (_optionalChain([auth, 'optionalAccess', _160 => _160.enabled]) !== true) {
7893
7918
  return { importSource: "", registerSource: "" };
7894
7919
  }
7895
7920
  return {
@@ -8208,26 +8233,26 @@ function generateVirtualEntryCode(apiRoutes, pageRoutes, layoutRoutes, routeSlot
8208
8233
  (route) => route.searchPreserve ? [route.searchPreserve] : []
8209
8234
  );
8210
8235
  const searchPreserveRoutesSource = searchPreserveRoutes.length > 0 ? JSON.stringify(searchPreserveRoutes) : "";
8211
- const farmIslandsMode = _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _166 => _166.experimental, 'optionalAccess', _167 => _167.serverComponents])) === "islands";
8212
- const farmRendererActions = _chunkP253SZJFcjs.resolveFarmIslxActionsMode.call(void 0, config) === "renderer";
8213
- const farmClientBoot = _chunkP253SZJFcjs.canBootFarmIslandsClient.call(void 0, config);
8236
+ const farmIslandsMode = _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _161 => _161.experimental, 'optionalAccess', _162 => _162.serverComponents])) === "islands";
8237
+ const farmRendererActions = _chunkTI4BZV6Mcjs.resolveFarmIslxActionsMode.call(void 0, config) === "renderer";
8238
+ const farmClientBoot = _chunkTI4BZV6Mcjs.canBootFarmIslandsClient.call(void 0, config);
8214
8239
  const farmMobileClient = shouldBuildFarmMobileClient(config);
8215
8240
  const farmMobileShells = farmMobileClient && config.mobileShells ? config.mobileShells : null;
8216
8241
  const hasCompressionRuntime = config.compress && _chunkOCS3PSYRcjs.resolveFarmInstrumentationRuntime.call(void 0, preset) !== "edge";
8217
- const servesAgentRobotsTxt = Boolean(_optionalChain([config, 'access', _168 => _168.agent, 'optionalAccess', _169 => _169.crawlers, 'optionalAccess', _170 => _170.enabled])) && !applicationMetadataRoutes.some(
8242
+ const servesAgentRobotsTxt = Boolean(_optionalChain([config, 'access', _163 => _163.agent, 'optionalAccess', _164 => _164.crawlers, 'optionalAccess', _165 => _165.enabled])) && !applicationMetadataRoutes.some(
8218
8243
  (metadata) => metadata.kind === "robots" && metadata.pattern === "/"
8219
8244
  );
8220
- const servesAgentSitemap = Boolean(_optionalChain([config, 'access', _171 => _171.agent, 'optionalAccess', _172 => _172.sitemap, 'optionalAccess', _173 => _173.enabled])) && !applicationMetadataRoutes.some(
8245
+ const servesAgentSitemap = Boolean(_optionalChain([config, 'access', _166 => _166.agent, 'optionalAccess', _167 => _167.sitemap, 'optionalAccess', _168 => _168.enabled])) && !applicationMetadataRoutes.some(
8221
8246
  (metadata) => metadata.kind === "sitemap" && metadata.pattern === "/"
8222
8247
  );
8223
- const servesDefaultMCP = _optionalChain([config, 'access', _174 => _174.agent, 'optionalAccess', _175 => _175.mcp]) === true && !_chunkW53Z4WDIcjs.farmConfigMountsMCP.call(void 0, config) && !apiRoutes.some((route) => route.path === "/api/mcp");
8224
- const servesAiCatalog = _optionalChain([config, 'access', _176 => _176.agent, 'optionalAccess', _177 => _177.aiCatalog]) !== false;
8248
+ const servesDefaultMCP = _optionalChain([config, 'access', _169 => _169.agent, 'optionalAccess', _170 => _170.mcp]) === true && !_chunkW53Z4WDIcjs.farmConfigMountsMCP.call(void 0, config) && !apiRoutes.some((route) => route.path === "/api/mcp");
8249
+ const servesAiCatalog = _optionalChain([config, 'access', _171 => _171.agent, 'optionalAccess', _172 => _172.aiCatalog]) !== false;
8225
8250
  const hasPluginRuntime = hasRuntimeIntegrationConfig || hasServerRuntimePlugins;
8226
8251
  const hasInfraAnalyticsRuntime = config.analytics !== false && _chunkOCS3PSYRcjs.resolveFarmInstrumentationRuntime.call(void 0, preset) === "nodejs";
8227
- const reportsWebMCPCalls = hasInfraAnalyticsRuntime && _chunkBAD6T5NUcjs._farmWebMCPReportsEnabled.call(void 0, config.plugins);
8252
+ const reportsWebMCPCalls = hasInfraAnalyticsRuntime && _chunk33WR5XV5cjs._farmWebMCPReportsEnabled.call(void 0, config.plugins);
8228
8253
  const hasPrecompiledDocs = Boolean(farmDocsPrecompiledManifest);
8229
8254
  const adapterOwnsDocsRuntime = _chunkL2GUEYHRcjs.hasFarmDocsRuntimeAdapter.call(void 0, config.docs);
8230
- if (_optionalChain([config, 'access', _178 => _178.docs, 'optionalAccess', _179 => _179.enabled]) && _optionalChain([config, 'access', _180 => _180.docs, 'access', _181 => _181.roots, 'optionalAccess', _182 => _182.length]) && !adapterOwnsDocsRuntime) {
8255
+ if (_optionalChain([config, 'access', _173 => _173.docs, 'optionalAccess', _174 => _174.enabled]) && _optionalChain([config, 'access', _175 => _175.docs, 'access', _176 => _176.roots, 'optionalAccess', _177 => _177.length]) && !adapterOwnsDocsRuntime) {
8231
8256
  throw new Error(
8232
8257
  "Several docs roots need a docs adapter; Farm's built-in docs renderer serves a single docs root."
8233
8258
  );
@@ -8235,7 +8260,7 @@ function generateVirtualEntryCode(apiRoutes, pageRoutes, layoutRoutes, routeSlot
8235
8260
  const docsConfigModulePath = adapterOwnsDocsRuntime && !hasPrecompiledDocs && config.docs.configPath && !config.docs.configPath.endsWith(".json") ? config.docs.configPath : void 0;
8236
8261
  const adapterHandler = generateFarmDocsAdapterHandlerArguments(config.docs, docsConfigModulePath);
8237
8262
  const hasIsolatedClientGraphRuntime = _chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) && isolatedClientBoundaryModules.size > 0;
8238
- const hasRendererIslandsGraph = isolatedClientBoundaryModules.size > 0 && _chunkCPSFDQKJcjs.usesFarmRendererIslands.call(void 0, config);
8263
+ const hasRendererIslandsGraph = isolatedClientBoundaryModules.size > 0 && _chunkZ43CIBURcjs.usesFarmRendererIslands.call(void 0, config);
8239
8264
  const rendererStreamingCapabilities = _chunkT7UC2ORAcjs.getFarmRendererStreamingCapabilitiesForRuntime.call(void 0,
8240
8265
  config.renderer,
8241
8266
  _chunkNLBHLPEOcjs.getFarmPresetRuntime.call(void 0, preset)
@@ -8299,8 +8324,8 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8299
8324
  (image) => image.sourceType === "module"
8300
8325
  );
8301
8326
  const edgeMiddlewareFilePaths = farmTargetRunsEdgeMiddleware(preset) ? middlewareRoutes.filter(isFarmEdgeMiddlewareRoute).map((route) => route.filePath) : [];
8302
- const hasMiddlewareRuntime = middlewareRoutes.length > 0 || _chunk4B6YJ5DScjs.hasFarmMiddlewareConfig.call(void 0, config.middleware);
8303
- const farmDocsFontAssets = _optionalChain([config, 'access', _183 => _183.docs, 'optionalAccess', _184 => _184.enabled]) ? _chunkERMUL73Lcjs.toFarmDocsPublicFontAssets.call(void 0, _chunkERMUL73Lcjs.resolveFarmDocsFontAssets.call(void 0, config.root)) : [];
8327
+ const hasMiddlewareRuntime = middlewareRoutes.length > 0 || _chunk4ZVKDHS6cjs.hasFarmMiddlewareConfig.call(void 0, config.middleware);
8328
+ const farmDocsFontAssets = _optionalChain([config, 'access', _178 => _178.docs, 'optionalAccess', _179 => _179.enabled]) ? _chunkERMUL73Lcjs.toFarmDocsPublicFontAssets.call(void 0, _chunkERMUL73Lcjs.resolveFarmDocsFontAssets.call(void 0, config.root)) : [];
8304
8329
  const integrationProviders = _chunkB3HQTGXScjs.getIntegrationProviders.call(void 0, config.integrations);
8305
8330
  const renderedIntegrationProviders = integrationProviders.filter(
8306
8331
  (provider) => provider.component || provider.type === "clerk"
@@ -8310,16 +8335,16 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8310
8335
  `Integration provider components are not supported by the "${config.renderer.name}" renderer.`
8311
8336
  );
8312
8337
  }
8313
- const providerServerModules = _chunkP253SZJFcjs.generateFarmIntegrationProviderServerModules.call(void 0,
8338
+ const providerServerModules = _chunkTI4BZV6Mcjs.generateFarmIntegrationProviderServerModules.call(void 0,
8314
8339
  renderedIntegrationProviders,
8315
8340
  config.root,
8316
8341
  _nullishCoalesce(config.renderer.componentExtensions, () => ( []))
8317
8342
  );
8318
8343
  const resolvedIntegrationProviderFallback = Object.fromEntries(
8319
8344
  Object.entries(config.integrations).flatMap(([name, integration]) => {
8320
- const configuredProviders = _optionalChain([integration, 'optionalAccess', _185 => _185.providers]);
8345
+ const configuredProviders = _optionalChain([integration, 'optionalAccess', _180 => _180.providers]);
8321
8346
  const providers = Array.isArray(configuredProviders) ? configuredProviders : [];
8322
- if (providers.some((provider) => typeof _optionalChain([provider, 'optionalAccess', _186 => _186.component]) === "function")) {
8347
+ if (providers.some((provider) => typeof _optionalChain([provider, 'optionalAccess', _181 => _181.component]) === "function")) {
8323
8348
  throw new Error(
8324
8349
  `Integration provider components in production must use an importable component reference, for example component: { module: "@/components/provider" }.`
8325
8350
  );
@@ -8330,22 +8355,22 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8330
8355
  const unsupportedIntegrationProvider = renderedIntegrationProviders.find(
8331
8356
  (provider) => provider.supportsIsolatedHydration !== true
8332
8357
  );
8333
- const isolatedHydrationMode = _chunkQYDGIXQ5cjs.resolveFarmIsolatedClientHydrationMode.call(void 0,
8334
- _optionalChain([config, 'access', _187 => _187.experimental, 'optionalAccess', _188 => _188.isolatedClientHydration]),
8358
+ const isolatedHydrationMode = _chunkU3A46QFDcjs.resolveFarmIsolatedClientHydrationMode.call(void 0,
8359
+ _optionalChain([config, 'access', _182 => _182.experimental, 'optionalAccess', _183 => _183.isolatedClientHydration]),
8335
8360
  {
8336
- serverComponents: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _189 => _189.experimental, 'optionalAccess', _190 => _190.serverComponents])) === "rsc",
8361
+ serverComponents: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _184 => _184.experimental, 'optionalAccess', _185 => _185.serverComponents])) === "rsc",
8337
8362
  hasUnsupportedIntegrationProvider: Boolean(unsupportedIntegrationProvider)
8338
8363
  }
8339
8364
  );
8340
- const hydrationPlanOptions = _chunkQYDGIXQ5cjs.getFarmClientHydrationPlanOptions.call(void 0,
8365
+ const hydrationPlanOptions = _chunkU3A46QFDcjs.getFarmClientHydrationPlanOptions.call(void 0,
8341
8366
  config.renderer,
8342
8367
  Boolean(unsupportedIntegrationProvider)
8343
8368
  );
8344
8369
  const pageHydrationPlanOptions = {
8345
8370
  ...hydrationPlanOptions,
8346
- serverOwners: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _191 => _191.experimental, 'optionalAccess', _192 => _192.serverComponents])) === "islands"
8371
+ serverOwners: _chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _186 => _186.experimental, 'optionalAccess', _187 => _187.serverComponents])) === "islands"
8347
8372
  };
8348
- const { layoutHydrationPlans, pageHydrationPlans } = _chunkQYDGIXQ5cjs.withFarmSourceSnapshot.call(void 0, () => {
8373
+ const { layoutHydrationPlans, pageHydrationPlans } = _chunkU3A46QFDcjs.withFarmSourceSnapshot.call(void 0, () => {
8349
8374
  const layoutHydrationPlans2 = layoutRoutes.map((layout) => ({
8350
8375
  ...layout,
8351
8376
  hydration: getCachedClientModuleHydrationPlan(
@@ -8356,7 +8381,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8356
8381
  { ...hydrationPlanOptions, serverTreeLayouts: pageHydrationPlanOptions.serverOwners }
8357
8382
  )
8358
8383
  }));
8359
- const markdownPagePlan = _chunkQYDGIXQ5cjs.createMarkdownPageHydrationPlanner.call(void 0,
8384
+ const markdownPagePlan = _chunkU3A46QFDcjs.createMarkdownPageHydrationPlanner.call(void 0,
8360
8385
  _chunk2HW5LWAHcjs.resolveFarmMdxComponentsModulePath.call(void 0, _chunk2HW5LWAHcjs.resolveMdxConfig.call(void 0, config.mdx), config.root),
8361
8386
  config.root,
8362
8387
  isolatedHydrationMode,
@@ -8376,7 +8401,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8376
8401
  );
8377
8402
  return { layoutHydrationPlans: layoutHydrationPlans2, pageHydrationPlans: pageHydrationPlans2 };
8378
8403
  });
8379
- _chunkQYDGIXQ5cjs.enforceFarmIsolatedHydrationRouteBudget.call(void 0,
8404
+ _chunkU3A46QFDcjs.enforceFarmIsolatedHydrationRouteBudget.call(void 0,
8380
8405
  layoutHydrationPlans.map((layout) => ({
8381
8406
  pattern: layout.pattern,
8382
8407
  depth: layout.pattern.split("/").filter(Boolean).length,
@@ -8385,10 +8410,10 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8385
8410
  pageRoutes.map((route) => ({
8386
8411
  // Compared by directory so a grouped layout applies only inside its group.
8387
8412
  pattern: _nullishCoalesce(route.directory, () => ( route.pattern)),
8388
- depth: _chunk4B6YJ5DScjs.getRouteDirectoryDepth.call(void 0, _nullishCoalesce(route.directory, () => ( route.pattern))),
8413
+ depth: _chunk4ZVKDHS6cjs.getRouteDirectoryDepth.call(void 0, _nullishCoalesce(route.directory, () => ( route.pattern))),
8389
8414
  metadata: pageHydrationPlans.get(route.modulePath)
8390
8415
  })),
8391
- _chunk4B6YJ5DScjs.routeBoundaryCoversDirectory,
8416
+ _chunk4ZVKDHS6cjs.routeBoundaryCoversDirectory,
8392
8417
  { serverOwners: pageHydrationPlanOptions.serverOwners }
8393
8418
  );
8394
8419
  const providerServerImports = [
@@ -8406,7 +8431,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8406
8431
  apiRegistrations.push(`
8407
8432
  {
8408
8433
  path: ${JSON.stringify(route.path)},
8409
- methods: ${JSON.stringify(route.methods.filter((method) => !_optionalChain([route, 'access', _193 => _193.pluginMethods, 'optionalAccess', _194 => _194.includes, 'call', _195 => _195(method)])))},
8434
+ methods: ${JSON.stringify(route.methods.filter((method) => !_optionalChain([route, 'access', _188 => _188.pluginMethods, 'optionalAccess', _189 => _189.includes, 'call', _190 => _190(method)])))},
8410
8435
  endpoints: ${varName},
8411
8436
  }`);
8412
8437
  });
@@ -8421,7 +8446,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8421
8446
  const varName = `pageRoute${index}`;
8422
8447
  if (_chunk26WP75W5cjs.isFarmMarkdownPageFile.call(void 0, route.modulePath)) {
8423
8448
  const renderingDirective2 = _chunkXMVZXZ32cjs.readRouteRenderingDirectiveFromFile.call(void 0, route.modulePath);
8424
- const markdownServerTree = pageHydrationPlanOptions.serverOwners && _chunkQYDGIXQ5cjs.usesFarmServerTree.call(void 0, pageHydrationPlans.get(route.modulePath));
8449
+ const markdownServerTree = pageHydrationPlanOptions.serverOwners && _chunkU3A46QFDcjs.usesFarmServerTree.call(void 0, pageHydrationPlans.get(route.modulePath));
8425
8450
  pageRegistrations.push(`
8426
8451
  {
8427
8452
  pattern: ${JSON.stringify(route.pattern)},${route.directory ? `
@@ -8429,14 +8454,14 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8429
8454
  rendering: ${JSON.stringify(renderingDirective2)},` : ""}${markdownServerTree ? "\n serverTree: true," : ""}
8430
8455
  module: createFarmMarkdownRouteModule({
8431
8456
  source: ${JSON.stringify(_nullishCoalesce(route.source, () => ( "")))},
8432
- filePath: ${JSON.stringify(_chunkP253SZJFcjs.toBakedMarkdownSourcePath.call(void 0, config.root, route.modulePath))},
8457
+ filePath: ${JSON.stringify(_chunkTI4BZV6Mcjs.toBakedMarkdownSourcePath.call(void 0, config.root, route.modulePath))},
8433
8458
  components: farmMdxComponents,
8434
8459
  config: farmMdxConfig,${_chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) ? "" : "\n renderer: React,"}
8435
8460
  }),
8436
8461
  markdownSource: {
8437
8462
  source: ${JSON.stringify(_nullishCoalesce(route.source, () => ( "")))},
8438
8463
  filePath: ${JSON.stringify(
8439
- _chunkP253SZJFcjs.toBakedMarkdownSourcePath.call(void 0, config.root, _nullishCoalesce(route.markdownSourcePath, () => ( route.modulePath)))
8464
+ _chunkTI4BZV6Mcjs.toBakedMarkdownSourcePath.call(void 0, config.root, _nullishCoalesce(route.markdownSourcePath, () => ( route.modulePath)))
8440
8465
  )},
8441
8466
  },
8442
8467
  }`);
@@ -8454,8 +8479,8 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8454
8479
  module: ${varName},
8455
8480
  shouldHydrate: ${JSON.stringify(clientMetadata.shouldHydrate)},${clientMetadata.shouldHydrate ? `
8456
8481
  clientModule: ${JSON.stringify(_chunk7U4XF76Rcjs.toViteModuleId.call(void 0, route.modulePath, config.root))},` : ""}
8457
- islandStrategy: ${JSON.stringify(clientMetadata.islandStrategy)},${_chunkQYDGIXQ5cjs.usesFarmServerTree.call(void 0, clientMetadata) ? "\n serverTree: true," : ""}${(() => {
8458
- const rootStrategy = _chunkP253SZJFcjs.resolveFarmRouteRootStrategy.call(void 0,
8482
+ islandStrategy: ${JSON.stringify(clientMetadata.islandStrategy)},${_chunkU3A46QFDcjs.usesFarmServerTree.call(void 0, clientMetadata) ? "\n serverTree: true," : ""}${(() => {
8483
+ const rootStrategy = _chunkTI4BZV6Mcjs.resolveFarmRouteRootStrategy.call(void 0,
8459
8484
  route,
8460
8485
  clientMetadata,
8461
8486
  layoutHydrationPlans.map((layout) => ({ ...layout, ...layout.hydration })),
@@ -8468,13 +8493,13 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8468
8493
  rendering: ${JSON.stringify(renderingDirective)},` : ""}
8469
8494
  ${route.source !== void 0 ? `markdownSource: {
8470
8495
  source: ${JSON.stringify(route.source)},
8471
- filePath: ${JSON.stringify(_chunkP253SZJFcjs.toBakedMarkdownSourcePath.call(void 0, config.root, route.markdownSourcePath))},
8496
+ filePath: ${JSON.stringify(_chunkTI4BZV6Mcjs.toBakedMarkdownSourcePath.call(void 0, config.root, route.markdownSourcePath))},
8472
8497
  },` : ""}
8473
8498
  }`);
8474
8499
  });
8475
8500
  const layoutImports = [];
8476
8501
  const layoutRegistrations = [];
8477
- const treeLayoutPatterns = farmIslandsMode ? _chunk4B6YJ5DScjs.getFarmServerTreeLayoutPatterns.call(void 0,
8502
+ const treeLayoutPatterns = farmIslandsMode ? _chunk4ZVKDHS6cjs.getFarmServerTreeLayoutPatterns.call(void 0,
8478
8503
  layoutHydrationPlans.map((layout) => ({
8479
8504
  pattern: layout.pattern,
8480
8505
  shouldHydrate: layout.hydration.shouldHydrate,
@@ -8492,7 +8517,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8492
8517
  pattern: ${JSON.stringify(layout.pattern)},
8493
8518
  module: ${varName},
8494
8519
  shouldHydrate: ${JSON.stringify(clientMetadata.shouldHydrate)},
8495
- islandStrategy: ${JSON.stringify(clientMetadata.islandStrategy)},${treeLayoutPatterns.has(layout.pattern) ? "\n serverTree: true," : ""}${farmIslandsMode && _chunkP253SZJFcjs.canFarmSkipKeptLayoutRender.call(void 0, layout.modulePath, config.root) ? "\n skipKeptRender: true," : ""}${// A layout whose client components hydrate as islands of their own (islands mode,
8520
+ islandStrategy: ${JSON.stringify(clientMetadata.islandStrategy)},${treeLayoutPatterns.has(layout.pattern) ? "\n serverTree: true," : ""}${farmIslandsMode && _chunkTI4BZV6Mcjs.canFarmSkipKeptLayoutRender.call(void 0, layout.modulePath, config.root) ? "\n skipKeptRender: true," : ""}${// A layout whose client components hydrate as islands of their own (islands mode,
8496
8521
  // isolatedClientHydration, or an async layout): it wraps a docs page as an app page.
8497
8522
  clientMetadata.hasIsolatedClientBoundaries ? "\n islands: true," : ""}
8498
8523
  }`);
@@ -8520,7 +8545,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8520
8545
  containerId: ${JSON.stringify(slot.containerId)},
8521
8546
  interception: ${JSON.stringify(slot.interception)},
8522
8547
  fallback: ${JSON.stringify(slot.fallback)},
8523
- hydrates: ${!farmIslandsMode || _chunkQYDGIXQ5cjs.getClientModuleMetadata.call(void 0, slot.modulePath, config.root).isClientComponent},
8548
+ hydrates: ${!farmIslandsMode || _chunkU3A46QFDcjs.getClientModuleMetadata.call(void 0, slot.modulePath, config.root).isClientComponent},
8524
8549
  module: ${varName},
8525
8550
  }`);
8526
8551
  });
@@ -8531,12 +8556,12 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8531
8556
  errorImports.push(
8532
8557
  `import * as ${varName} from ${toVirtualEntryImportSpecifier(errorRoute.modulePath)};`
8533
8558
  );
8534
- const groupScope = _chunk4B6YJ5DScjs.getRouteGroupScope.call(void 0, errorRoute.pattern);
8559
+ const groupScope = _chunk4ZVKDHS6cjs.getRouteGroupScope.call(void 0, errorRoute.pattern);
8535
8560
  errorRegistrations.push(`
8536
8561
  {
8537
- pattern: ${JSON.stringify(_chunk4B6YJ5DScjs.stripRouteGroups.call(void 0, errorRoute.pattern))},${groupScope ? `
8562
+ pattern: ${JSON.stringify(_chunk4ZVKDHS6cjs.stripRouteGroups.call(void 0, errorRoute.pattern))},${groupScope ? `
8538
8563
  groupScope: ${JSON.stringify(groupScope)},
8539
- directoryDepth: ${_chunk4B6YJ5DScjs.getRouteDirectoryDepth.call(void 0, errorRoute.pattern)},` : ""}
8564
+ directoryDepth: ${_chunk4ZVKDHS6cjs.getRouteDirectoryDepth.call(void 0, errorRoute.pattern)},` : ""}
8540
8565
  module: ${varName},
8541
8566
  }`);
8542
8567
  });
@@ -8548,12 +8573,12 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8548
8573
  loadingImports.push(
8549
8574
  `import * as ${varName} from ${toVirtualEntryImportSpecifier(loadingRoute.modulePath)};`
8550
8575
  );
8551
- const groupScope = _chunk4B6YJ5DScjs.getRouteGroupScope.call(void 0, loadingRoute.pattern);
8576
+ const groupScope = _chunk4ZVKDHS6cjs.getRouteGroupScope.call(void 0, loadingRoute.pattern);
8552
8577
  loadingRegistrations.push(`
8553
8578
  {
8554
- pattern: ${JSON.stringify(_chunk4B6YJ5DScjs.stripRouteGroups.call(void 0, loadingRoute.pattern))},${groupScope ? `
8579
+ pattern: ${JSON.stringify(_chunk4ZVKDHS6cjs.stripRouteGroups.call(void 0, loadingRoute.pattern))},${groupScope ? `
8555
8580
  groupScope: ${JSON.stringify(groupScope)},
8556
- directoryDepth: ${_chunk4B6YJ5DScjs.getRouteDirectoryDepth.call(void 0, loadingRoute.pattern)},` : ""}
8581
+ directoryDepth: ${_chunk4ZVKDHS6cjs.getRouteDirectoryDepth.call(void 0, loadingRoute.pattern)},` : ""}
8557
8582
  module: ${varName},
8558
8583
  }`);
8559
8584
  });
@@ -8566,7 +8591,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8566
8591
  metadataImageImports.push(
8567
8592
  `import * as ${varName} from ${toVirtualEntryImportSpecifier(image.modulePath)};`
8568
8593
  );
8569
- const component = !_chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) && _chunkP253SZJFcjs.isRendererCompiledComponent.call(void 0, image.modulePath, _nullishCoalesce(_optionalChain([config, 'access', _196 => _196.renderer, 'optionalAccess', _197 => _197.componentExtensions]), () => ( [])));
8594
+ const component = !_chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) && _chunkTI4BZV6Mcjs.isRendererCompiledComponent.call(void 0, image.modulePath, _nullishCoalesce(_optionalChain([config, 'access', _191 => _191.renderer, 'optionalAccess', _192 => _192.componentExtensions]), () => ( [])));
8570
8595
  metadataImageRegistrations.push(`
8571
8596
  {
8572
8597
  pattern: ${JSON.stringify(image.pattern)},
@@ -8642,7 +8667,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8642
8667
  createDefaultErrorMarkup,
8643
8668
  createFarmInstrumentationLifecycle,
8644
8669
  createFarmLayoutSelector,
8645
- createFarmLayoutBoundary,${_optionalChain([config, 'access', _198 => _198.docs, 'optionalAccess', _199 => _199.enabled]) ? "\n createFarmDocsLayoutTree,\n farmDocsLayoutsWrapPage,\n placeFarmDocsLayoutRoot," : ""}
8670
+ createFarmLayoutBoundary,${_optionalChain([config, 'access', _193 => _193.docs, 'optionalAccess', _194 => _194.enabled]) ? "\n createFarmDocsLayoutTree,\n farmDocsLayoutsWrapPage,\n placeFarmDocsLayoutRoot," : ""}
8646
8671
  isInFarmRouteGroupScope,
8647
8672
  routeBoundaryCoversDirectory,
8648
8673
  createFarmCacheKey,
@@ -8726,7 +8751,7 @@ function renderFarmServerTreeLayout(Layout, props, outlets) {
8726
8751
  createFarmDeploymentMismatchResponse,
8727
8752
  FARM_DEPLOYMENT_ID_HEADER,
8728
8753
  getFarmDeploymentMismatch,
8729
- withoutFarmDeploymentCookie,${config.mobileClient ? "\n createFarmNativeTreeResponse," : ""}${config.trailingSlash && (_optionalChain([config, 'access', _200 => _200.md, 'optionalAccess', _201 => _201.enabled]) || hasMarkdownPages) ? "\n toFarmTrailingSlashPageRequest," : ""}${hasInfraAnalyticsRuntime ? "\n resolveFarmDocsEngineRouteLabel,\n resolveFarmDocsRouteLabel,\n resolveFarmMarkdownRouteLabel,\n resolveFarmMCPRouteLabel,\n setFarmRouteLabel," : ""}${hasFarmServerStorageConfig(config.storage) ? "\n _registerFarmStorageModules,\n disposeFarmStorage,\n initFarmStorage," : ""}${searchPreserveRoutesSource ? "\n _setFarmSearchPreserveRoutes," : ""}
8754
+ withoutFarmDeploymentCookie,${config.mobileClient ? "\n createFarmNativeTreeResponse," : ""}${config.trailingSlash && (_optionalChain([config, 'access', _195 => _195.md, 'optionalAccess', _196 => _196.enabled]) || hasMarkdownPages) ? "\n toFarmTrailingSlashPageRequest," : ""}${hasInfraAnalyticsRuntime ? "\n resolveFarmDocsEngineRouteLabel,\n resolveFarmDocsRouteLabel,\n resolveFarmMarkdownRouteLabel,\n resolveFarmMCPRouteLabel,\n setFarmRouteLabel," : ""}${hasFarmServerStorageConfig(config.storage) ? "\n _registerFarmStorageModules,\n disposeFarmStorage,\n initFarmStorage," : ""}${searchPreserveRoutesSource ? "\n _setFarmSearchPreserveRoutes," : ""}
8730
8755
  } from "@farm.js/core/internal/production-runtime";${farmMobileClient ? `
8731
8756
  import { _applyFarmMobileShellClient } from "@farm.js/core/internal/production-runtime";
8732
8757
  // The mobile client documents load when a mobile shell asks for them (RFC 0004, 7.2), filled in
@@ -8798,25 +8823,25 @@ function farmFormStateScript() { return ""; }`}`;
8798
8823
  const infraAnalyticsImport = hasInfraAnalyticsRuntime ? `import { ${hasPluginRuntime ? "createFarmInfraAnalyticsPlugin" : "createFarmInfraAnalyticsRecorder"} } from "@farm.js/core/internal/infra-analytics-runtime";` : "";
8799
8824
  const compressionRuntimeImport = hasCompressionRuntime ? `import { compressFarmResponse${hasPluginRuntime ? ", createCompressionPlugin" : ""} } from "@farm.js/core/internal/compression-runtime";` : "";
8800
8825
  const i18nServerImport = config.i18n.enabled ? `import { _runWithFarmI18nRequest, _setDefaultFarmI18nRuntime, createFarmI18nRuntime, getFarmI18nClientSnapshot } from "@farm.js/core/i18n/server";` : "";
8801
- const docsHandlerImport = _optionalChain([config, 'access', _202 => _202.docs, 'optionalAccess', _203 => _203.enabled]) ? hasPrecompiledDocs ? `import { createFarmDocsPrecompiledRuntime } from "@farm.js/core/internal/docs-precompiled-runtime";
8826
+ const docsHandlerImport = _optionalChain([config, 'access', _197 => _197.docs, 'optionalAccess', _198 => _198.enabled]) ? hasPrecompiledDocs ? `import { createFarmDocsPrecompiledRuntime } from "@farm.js/core/internal/docs-precompiled-runtime";
8802
8827
  const isFarmDocsAPIRequest = (requestOrPathname) => {
8803
8828
  const pathname = typeof requestOrPathname === "string"
8804
8829
  ? requestOrPathname
8805
8830
  : new URL(requestOrPathname.url).pathname;
8806
- const apiPath = ${JSON.stringify(_optionalChain([farmDocsPrecompiledManifest, 'optionalAccess', _204 => _204.apiPath]) || "/api/docs")};
8831
+ const apiPath = ${JSON.stringify(_optionalChain([farmDocsPrecompiledManifest, 'optionalAccess', _199 => _199.apiPath]) || "/api/docs")};
8807
8832
  return pathname === apiPath || pathname.startsWith(apiPath + "/");
8808
8833
  };` : adapterOwnsDocsRuntime ? `import { ${docsConfigModulePath ? "getFarmDocsConfigModuleRoot, " : ""}isFarmDocsAPIRequest } from "@farm.js/core/docs";
8809
- import { ${_optionalChain([config, 'access', _205 => _205.docs, 'access', _206 => _206.roots, 'optionalAccess', _207 => _207.length]) ? "createFarmDocsMultiRuntimeHandler as createFarmDocsAdapterMultiRuntimeHandler" : "createFarmDocsRuntimeHandler as createFarmDocsAdapterRuntimeHandler"} } from ${JSON.stringify(config.docs.adapter.server)};
8834
+ import { ${_optionalChain([config, 'access', _200 => _200.docs, 'access', _201 => _201.roots, 'optionalAccess', _202 => _202.length]) ? "createFarmDocsMultiRuntimeHandler as createFarmDocsAdapterMultiRuntimeHandler" : "createFarmDocsRuntimeHandler as createFarmDocsAdapterRuntimeHandler"} } from ${JSON.stringify(config.docs.adapter.server)};
8810
8835
  import * as FarmDocsAdapterUI from ${JSON.stringify(_chunkL2GUEYHRcjs.getFarmDocsAdapterUIModule.call(void 0, config.docs.adapter))};${docsConfigModulePath ? `
8811
8836
  import * as farmDocsConfigModule from ${toVirtualEntryImportSpecifier(docsConfigModulePath)};` : ""}` : `import { createFarmDocsAPIHandler, createFarmDocsHandler, isFarmDocsAPIRequest } from "@farm.js/core/docs";` : "";
8812
- const docsFontImport = _optionalChain([config, 'access', _208 => _208.docs, 'optionalAccess', _209 => _209.enabled]) && !hasPrecompiledDocs ? `import { resolveFarmLayoutFonts } from "@farm.js/core/font";` : "";
8813
- const docsRuntimeImport = _optionalChain([config, 'access', _210 => _210.docs, 'optionalAccess', _211 => _211.enabled]) && !hasPrecompiledDocs ? `import { existsSync as farmDocsExistsSync } from "node:fs";
8837
+ const docsFontImport = _optionalChain([config, 'access', _203 => _203.docs, 'optionalAccess', _204 => _204.enabled]) && !hasPrecompiledDocs ? `import { resolveFarmLayoutFonts } from "@farm.js/core/font";` : "";
8838
+ const docsRuntimeImport = _optionalChain([config, 'access', _205 => _205.docs, 'optionalAccess', _206 => _206.enabled]) && !hasPrecompiledDocs ? `import { existsSync as farmDocsExistsSync } from "node:fs";
8814
8839
  import { dirname as farmDocsDirname, join as farmDocsJoin } from "node:path";
8815
8840
  import { fileURLToPath as farmDocsFileURLToPath } from "node:url";` : "";
8816
- const markdownHandlerImport = _optionalChain([config, 'access', _212 => _212.md, 'optionalAccess', _213 => _213.enabled]) ? `import { applyMarkdownNegotiationHeaders, createMarkdownMirrorResponse, getFarmMarkdownAlternatePath } from "@farm.js/core/markdown";` : "";
8841
+ const markdownHandlerImport = _optionalChain([config, 'access', _207 => _207.md, 'optionalAccess', _208 => _208.enabled]) ? `import { applyMarkdownNegotiationHeaders, createMarkdownMirrorResponse, getFarmMarkdownAlternatePath } from "@farm.js/core/markdown";` : "";
8817
8842
  const appMarkdownImport = hasMarkdownPages ? `import { FARM_MARKDOWN_ANONYMOUS_CLIENT_ADDRESS, createFarmMarkdownRouteModule, createFarmMarkdownSourceResponse, isFarmMarkdownPublicSourceResponse } from "@farm.js/core/internal/app-markdown-runtime";` : "const createFarmMarkdownSourceResponse = null;\nconst isFarmMarkdownPublicSourceResponse = null;";
8818
8843
  const markdownErrorImport = `import { FARM_MARKDOWN_CONTENT_TYPE, FARM_MARKDOWN_PAGE_CHECK_HEADER, _isFarmMarkdownPageCheck, createFarmMarkdownErrorBody, farmRequestWantsMarkdown } from "@farm.js/core/markdown";`;
8819
- const mdxComponentsPath = typeof _optionalChain([config, 'access', _214 => _214.mdx, 'optionalAccess', _215 => _215.components]) === "string" ? _path2.default.isAbsolute(config.mdx.components) ? config.mdx.components : _path2.default.join(config.root, config.mdx.components) : null;
8844
+ const mdxComponentsPath = typeof _optionalChain([config, 'access', _209 => _209.mdx, 'optionalAccess', _210 => _210.components]) === "string" ? _path2.default.isAbsolute(config.mdx.components) ? config.mdx.components : _path2.default.join(config.root, config.mdx.components) : null;
8820
8845
  const mdxComponentsImport = mdxComponentsPath ? `import * as FarmMdxComponentsModule from ${toVirtualEntryImportSpecifier(mdxComponentsPath)};` : "";
8821
8846
  const layerConfigPaths = (config.layers || []).map((layer) => layer.configFile).filter((configFile) => Boolean(configFile)).filter((configFile) => configFile !== configModulePath);
8822
8847
  const layerConfigImports = layerConfigPaths.map(
@@ -8836,14 +8861,14 @@ import { fileURLToPath as farmDocsFileURLToPath } from "node:url";` : "";
8836
8861
  const nativeAuth = generateNativeAuthIntegrationSource(config.auth);
8837
8862
  const nativeMCP = _chunkVM57CK74cjs.generateNativeMCPPluginSource.call(void 0, config.mcp);
8838
8863
  const mobileSession = (config.plugins || []).some(
8839
- (plugin) => _optionalChain([plugin, 'optionalAccess', _216 => _216.name]) === _chunkMHKPXX3Jcjs.FARM_MOBILE_SESSION_PLUGIN
8864
+ (plugin) => _optionalChain([plugin, 'optionalAccess', _211 => _211.name]) === _chunkMHKPXX3Jcjs.FARM_MOBILE_SESSION_PLUGIN
8840
8865
  );
8841
8866
  const nativeServerFns = (config.plugins || []).some(
8842
- (plugin) => _optionalChain([plugin, 'optionalAccess', _217 => _217.name]) === _chunk4EBC7EMWcjs.FARM_NATIVE_SERVER_FN_PLUGIN
8843
- ) ? _chunkUDWBTABTcjs.collectFarmNativeServerFns.call(void 0, {
8867
+ (plugin) => _optionalChain([plugin, 'optionalAccess', _212 => _212.name]) === _chunk4EBC7EMWcjs.FARM_NATIVE_SERVER_FN_PLUGIN
8868
+ ) ? _chunkRGYS5OPLcjs.collectFarmNativeServerFns.call(void 0, {
8844
8869
  root: config.root,
8845
8870
  srcDir: config.srcDir,
8846
- entries: _chunkUDWBTABTcjs.findFarmNativeScreenFiles.call(void 0, _chunk52Q4OB4Acjs.getFarmAppDirectories.call(void 0, config))
8871
+ entries: _chunkRGYS5OPLcjs.findFarmNativeScreenFiles.call(void 0, _chunk52Q4OB4Acjs.getFarmAppDirectories.call(void 0, config))
8847
8872
  }) : void 0;
8848
8873
  const integrationImports = `
8849
8874
  ${configModulePath ? `import * as FarmUserConfigModule from ${toVirtualEntryImportSpecifier(configModulePath)};` : ""}
@@ -8858,7 +8883,7 @@ ${nativeServerFns ? `const __farmNativeServerFnRegistry = Object.assign(Object.c
8858
8883
  ${nativeServerFns.flatMap((module, index) => module.exports.map((entry) => ` ${JSON.stringify(entry.id)}: __farmNativeServerFns${index}[${JSON.stringify(entry.name)}],`)).join("\n")}
8859
8884
  });` : ""}
8860
8885
  `;
8861
- const imageRuntime = _chunkP253SZJFcjs.resolveFarmImageServerRuntime.call(void 0, config.images, preset);
8886
+ const imageRuntime = _chunkTI4BZV6Mcjs.resolveFarmImageServerRuntime.call(void 0, config.images, preset);
8862
8887
  const imageRuntimeImport = imageRuntime === "none" ? "" : `import { _withFarmImageSourceClientAddress, createCloudflareImageTransformer, createFarmImageHandler } from "@farm.js/core/image/server";`;
8863
8888
  const imageNodeRuntimeImport = imageRuntime === "node" ? `import { createNodeImageFetcher, createNodeImageUrlValidator, createSharpImageTransformer } from "@farm.js/core/image/sharp";` : "";
8864
8889
  const apiHandlerCode = apiRoutes.length > 0 ? `
@@ -9040,7 +9065,7 @@ const farmResolvedRuntimeConfig = Object.assign({}, ...farmRuntimeConfigs);
9040
9065
 
9041
9066
  function renderFarmDefault404Page() {
9042
9067
  return React.createElement(React.Fragment, null,
9043
- React.createElement("style", null, ${JSON.stringify(_chunkP253SZJFcjs.DEFAULT_NOT_FOUND_STYLES)}),
9068
+ React.createElement("style", null, ${JSON.stringify(_chunkTI4BZV6Mcjs.DEFAULT_NOT_FOUND_STYLES)}),
9044
9069
  React.createElement("main", {
9045
9070
  className: "farm-default-not-found",
9046
9071
  "aria-labelledby": "farm-default-not-found-title",
@@ -9196,24 +9221,24 @@ const farmImageHandler = ${imageRuntime === "none" ? "null" : imageRuntime === "
9196
9221
  validateRemoteUrl: createNodeImageUrlValidator(${JSON.stringify(config.images)}),
9197
9222
  onError(error) { console.error("[Farm Image]", error); },
9198
9223
  })`};
9199
- const farmMarkdownConfig = ${JSON.stringify(config.md)};${_optionalChain([config, 'access', _218 => _218.md, 'optionalAccess', _219 => _219.enabled]) || hasMarkdownPages ? config.trailingSlash ? `
9224
+ const farmMarkdownConfig = ${JSON.stringify(config.md)};${_optionalChain([config, 'access', _213 => _213.md, 'optionalAccess', _214 => _214.enabled]) || hasMarkdownPages ? config.trailingSlash ? `
9200
9225
  // A Markdown mirror, and a page.md source's page check, read the page at the URL it answers at
9201
9226
  // ('/about/'), so the trailing-slash 308 never answers in its place.
9202
9227
  const toFarmMarkdownPageRequest = (request) => toFarmTrailingSlashPageRequest(request, true);` : `
9203
9228
  const toFarmMarkdownPageRequest = (request) => request;` : ""}
9204
- const farmLlmsTxtConfig = ${JSON.stringify(_nullishCoalesce(_optionalChain([config, 'access', _220 => _220.agent, 'optionalAccess', _221 => _221.llmsTxt]), () => ( { enabled: false, include: [], exclude: [] })))};
9205
- ${_optionalChain([config, 'access', _222 => _222.agent, 'optionalAccess', _223 => _223.llmsTxt, 'optionalAccess', _224 => _224.enabled]) ? "const farmLlmsFullRenderer = createFarmLlmsFullRenderer({ revalidate: farmLlmsTxtConfig.revalidate });\n" : ""}${servesAgentRobotsTxt ? `const farmAgentCrawlers = ${JSON.stringify(config.agent.crawlers)};` : ""}
9229
+ const farmLlmsTxtConfig = ${JSON.stringify(_nullishCoalesce(_optionalChain([config, 'access', _215 => _215.agent, 'optionalAccess', _216 => _216.llmsTxt]), () => ( { enabled: false, include: [], exclude: [] })))};
9230
+ ${_optionalChain([config, 'access', _217 => _217.agent, 'optionalAccess', _218 => _218.llmsTxt, 'optionalAccess', _219 => _219.enabled]) ? "const farmLlmsFullRenderer = createFarmLlmsFullRenderer({ revalidate: farmLlmsTxtConfig.revalidate });\n" : ""}${servesAgentRobotsTxt ? `const farmAgentCrawlers = ${JSON.stringify(config.agent.crawlers)};` : ""}
9206
9231
  const farmMdxConfig = ${JSON.stringify({
9207
9232
  ...config.mdx,
9208
- components: typeof _optionalChain([config, 'access', _225 => _225.mdx, 'optionalAccess', _226 => _226.components]) === "string" ? config.mdx.components : void 0
9233
+ components: typeof _optionalChain([config, 'access', _220 => _220.mdx, 'optionalAccess', _221 => _221.components]) === "string" ? config.mdx.components : void 0
9209
9234
  })};
9210
9235
  const configuredFarmMdxComponents = farmUserConfig?.mdx?.components;
9211
- ${_optionalChain([config, 'access', _227 => _227.agent, 'optionalAccess', _228 => _228.noindexPreviews]) ? `// agent.noindexPreviews: the runtime environment decides, falling back to the
9236
+ ${_optionalChain([config, 'access', _222 => _222.agent, 'optionalAccess', _223 => _223.noindexPreviews]) ? `// agent.noindexPreviews: the runtime environment decides, falling back to the
9212
9237
  // environment this was built in, since Netlify exposes its deploy context only
9213
9238
  // to the build.
9214
9239
  const farmNoindexPreview = resolveFarmPreviewDeployment(
9215
9240
  globalThis.process?.env,
9216
- ${JSON.stringify(_chunkNXOZRI3Bcjs.isFarmPreviewDeploymentEnvironment.call(void 0, process.env))},
9241
+ ${JSON.stringify(_chunkIM422XKUcjs.isFarmPreviewDeploymentEnvironment.call(void 0, process.env))},
9217
9242
  );` : ""}
9218
9243
  const farmMdxComponents = ${mdxComponentsPath ? `(FarmMdxComponentsModule.components || Reflect.get(FarmMdxComponentsModule, "default") || {})` : `(configuredFarmMdxComponents && typeof configuredFarmMdxComponents === "object" ? configuredFarmMdxComponents : {})`};
9219
9244
  const farmObservabilityConfig = farmUserConfig?.observability ?? ${JSON.stringify(
@@ -9259,7 +9284,7 @@ export const farmProductionLifecycle = createFarmProductionLifecycle({
9259
9284
  });
9260
9285
  const farmI18nRuntime = ${config.i18n.enabled ? `createFarmI18nRuntime(farmI18nConfig, ${JSON.stringify(i18nCatalogs)})` : "null"};
9261
9286
  ${config.i18n.enabled ? "_setDefaultFarmI18nRuntime(farmI18nRuntime);" : ""}
9262
- const farmDocsBundledContentDir = ${_optionalChain([config, 'access', _229 => _229.docs, 'optionalAccess', _230 => _230.enabled]) && !hasPrecompiledDocs ? `(() => {
9287
+ const farmDocsBundledContentDir = ${_optionalChain([config, 'access', _224 => _224.docs, 'optionalAccess', _225 => _225.enabled]) && !hasPrecompiledDocs ? `(() => {
9263
9288
  try {
9264
9289
  const currentDir = farmDocsDirname(farmDocsFileURLToPath(import.meta.url));
9265
9290
  const candidates = [
@@ -9271,7 +9296,7 @@ const farmDocsBundledContentDir = ${_optionalChain([config, 'access', _229 => _2
9271
9296
  } catch {
9272
9297
  return null;
9273
9298
  }
9274
- })()` : "null"};${_optionalChain([config, 'access', _231 => _231.docs, 'optionalAccess', _232 => _232.enabled]) && !hasPrecompiledDocs && _optionalChain([config, 'access', _233 => _233.docs, 'access', _234 => _234.roots, 'optionalAccess', _235 => _235.length]) ? `
9299
+ })()` : "null"};${_optionalChain([config, 'access', _226 => _226.docs, 'optionalAccess', _227 => _227.enabled]) && !hasPrecompiledDocs && _optionalChain([config, 'access', _228 => _228.docs, 'access', _229 => _229.roots, 'optionalAccess', _230 => _230.length]) ? `
9275
9300
  const farmDocsBundledRootsDir = (() => {
9276
9301
  try {
9277
9302
  const currentDir = farmDocsDirname(farmDocsFileURLToPath(import.meta.url));
@@ -9325,7 +9350,7 @@ const farmDocsModulePreloadPaths = farmDocsModulePreloads
9325
9350
  : undefined;
9326
9351
  ${adapterOwnsDocsRuntime && !hasPrecompiledDocs ? `// The renderer contract's server exports, for a docs UI that builds its pages with them.
9327
9352
  const farmDocsAppRenderer = ${_chunkT7UC2ORAcjs.isReactRenderer.call(void 0, config.renderer) ? '{ name: "react", createElement: React.createElement, Fragment: React.Fragment, renderToString: ReactDOMServer.renderToString }' : "__farmRendererServer"};
9328
- ` : ""}const farmDocsHandler = ${_optionalChain([config, 'access', _236 => _236.docs, 'optionalAccess', _237 => _237.enabled]) ? hasPrecompiledDocs ? "farmDocsPrecompiledRuntime.handleDocsRequest" : adapterOwnsDocsRuntime ? `${adapterHandler.factory}(${adapterHandler.config}, {
9353
+ ` : ""}const farmDocsHandler = ${_optionalChain([config, 'access', _231 => _231.docs, 'optionalAccess', _232 => _232.enabled]) ? hasPrecompiledDocs ? "farmDocsPrecompiledRuntime.handleDocsRequest" : adapterOwnsDocsRuntime ? `${adapterHandler.factory}(${adapterHandler.config}, {
9329
9354
  rootDir: farmDocsRuntimeRoot,
9330
9355
  // A production build's content cannot change, so the adapter reads its
9331
9356
  // navigation once instead of scanning the content directory per request.
@@ -9349,7 +9374,7 @@ const farmDocsAppRenderer = ${_chunkT7UC2ORAcjs.isReactRenderer.call(void 0, con
9349
9374
  registerMCPServer: registerFarmMCPServer,
9350
9375
  // A page built with this keeps its HTML string, so the preload budget and the response
9351
9376
  // writer use it instead of reading and re-encoding the body. Older adapters ignore it.
9352
- createHtmlResponse: farmOwnedHtmlResponse,${_chunkBLZCAFGJcjs.farmDocsAdapterServesGuardedPages.call(void 0, config.docs) ? `
9377
+ createHtmlResponse: farmOwnedHtmlResponse,${_chunkCXHVRHM2cjs.farmDocsAdapterServesGuardedPages.call(void 0, config.docs) ? `
9353
9378
  // The adapter keeps pages a path guard covers off search, llms.txt, the sitemap and MCP. It
9354
9379
  // asks about any path its own content lists, so the guards decide here, not a page list.
9355
9380
  isPathGuarded: (pathname) =>
@@ -9375,7 +9400,7 @@ const farmDocsAppRenderer = ${_chunkT7UC2ORAcjs.isReactRenderer.call(void 0, con
9375
9400
  isPathGuarded: isFarmDocsPathGuarded,
9376
9401
  basePath: ${JSON.stringify(config.basePath)},
9377
9402
  })` : "null"};
9378
- const farmDocsAPIHandler = ${_optionalChain([config, 'access', _238 => _238.docs, 'optionalAccess', _239 => _239.enabled]) ? hasPrecompiledDocs ? "farmDocsPrecompiledRuntime.handleAPIRequest" : adapterOwnsDocsRuntime ? "null" : `createFarmDocsAPIHandler({ rootDir: farmDocsRuntimeRoot, srcDir: ${JSON.stringify(config.srcDir)}, docs: farmDocsResolvedConfig, isPathGuarded: isFarmDocsPathGuarded, basePath: ${JSON.stringify(config.basePath)} })` : "null"};
9403
+ const farmDocsAPIHandler = ${_optionalChain([config, 'access', _233 => _233.docs, 'optionalAccess', _234 => _234.enabled]) ? hasPrecompiledDocs ? "farmDocsPrecompiledRuntime.handleAPIRequest" : adapterOwnsDocsRuntime ? "null" : `createFarmDocsAPIHandler({ rootDir: farmDocsRuntimeRoot, srcDir: ${JSON.stringify(config.srcDir)}, docs: farmDocsResolvedConfig, isPathGuarded: isFarmDocsPathGuarded, basePath: ${JSON.stringify(config.basePath)} })` : "null"};
9379
9404
 
9380
9405
  // API routes bundled at build time
9381
9406
  const apiRoutes = ${apiRoutes.length > 0 ? "mergePluginAPIRoutes(" : ""}[${apiRegistrations.join(",")}
@@ -9410,12 +9435,12 @@ const farmDeploymentCookiePath = ${JSON.stringify(config.basePath || "/")};
9410
9435
  // runtime request.
9411
9436
  const farmRuntimeErrorSlot = Symbol("farm.runtime.error.slot");
9412
9437
  const farmOpenAPIReference = ${JSON.stringify(openAPIReference)};
9413
- ${_optionalChain([config, 'access', _240 => _240.agent, 'optionalAccess', _241 => _241.apiCatalog]) ? `const farmApiCatalogInput = ${JSON.stringify(_chunkTQJ35BBWcjs.resolveFarmApiCatalogInput.call(void 0, config))};
9414
- ` : ""}${_optionalChain([config, 'access', _242 => _242.agent, 'optionalAccess', _243 => _243.manifest]) !== false ? `const farmAppManifestInput = ${JSON.stringify(
9415
- _chunkTQJ35BBWcjs.resolveFarmAppManifestInput.call(void 0, config, {
9438
+ ${_optionalChain([config, 'access', _235 => _235.agent, 'optionalAccess', _236 => _236.apiCatalog]) ? `const farmApiCatalogInput = ${JSON.stringify(_chunkXFUPWRKTcjs.resolveFarmApiCatalogInput.call(void 0, config))};
9439
+ ` : ""}${_optionalChain([config, 'access', _237 => _237.agent, 'optionalAccess', _238 => _238.manifest]) !== false ? `const farmAppManifestInput = ${JSON.stringify(
9440
+ _chunkXFUPWRKTcjs.resolveFarmAppManifestInput.call(void 0, config, {
9416
9441
  build: config.deploymentId,
9417
- packages: _chunkP253SZJFcjs.resolveFarmAppPackages.call(void 0, config.root),
9418
- webmcpTools: config.plugins.some(({ name }) => name === "farm:webmcp") ? _chunkP253SZJFcjs.collectFarmWebMCPTools.call(void 0, config.root, config.srcDir) : []
9442
+ packages: _chunkTI4BZV6Mcjs.resolveFarmAppPackages.call(void 0, config.root),
9443
+ webmcpTools: config.plugins.some(({ name }) => name === "farm:webmcp") ? _chunkTI4BZV6Mcjs.collectFarmWebMCPTools.call(void 0, config.root, config.srcDir) : []
9419
9444
  })
9420
9445
  )};
9421
9446
  ${servesDefaultMCP ? "farmAppManifestInput.defaultMCP = getFarmDefaultMCPServer;\n" : ""}// A guard written for an MCP server's path keeps its tools out of the public view.
@@ -9428,7 +9453,7 @@ farmAppManifestInput.guardCoversPath = (path) =>
9428
9453
  path,
9429
9454
  farmLocalAPIBasePath,
9430
9455
  );
9431
- ${_optionalChain([config, 'access', _244 => _244.docs, 'optionalAccess', _245 => _245.enabled]) ? `// A docs runtime's MCP server lists its tools when asked over MCP, in process. A build
9456
+ ${_optionalChain([config, 'access', _239 => _239.docs, 'optionalAccess', _240 => _240.enabled]) ? `// A docs runtime's MCP server lists its tools when asked over MCP, in process. A build
9432
9457
  // can't change them, so they are read once.
9433
9458
  if (farmDocsHandler) {
9434
9459
  farmAppManifestInput.registeredMCP = (request) =>
@@ -10203,7 +10228,7 @@ function peelFarmDocumentPrefix(markup) {
10203
10228
  let inner = markup.replace(/^\\s+/, "");
10204
10229
  let hoisted = "";
10205
10230
  const wrapper = /^<div\\b[^>]*style=["']display\\s*:\\s*contents;?\\s*["'][^>]*>/i;
10206
- const hoistable = /${_chunk4B6YJ5DScjs.HOISTED_HEAD_ELEMENT.source}/i;
10231
+ const hoistable = /${_chunk4ZVKDHS6cjs.HOISTED_HEAD_ELEMENT.source}/i;
10207
10232
  let match;
10208
10233
  while ((match = wrapper.exec(inner) || hoistable.exec(inner))) {
10209
10234
  if (!/^<div/i.test(match[0])) hoisted += match[0];
@@ -10232,7 +10257,7 @@ function opensFarmFullDocument(markup) {
10232
10257
  // them: its own head takes them. Matches the dev renderer's takeFarmHoistedHead.
10233
10258
  function takeFarmHoistedHead(markup) {
10234
10259
  if (opensFarmFullDocument(markup)) return { head: "", body: markup };
10235
- const hoistable = /${_chunk4B6YJ5DScjs.HOISTED_HEAD_ELEMENT.source}/i;
10260
+ const hoistable = /${_chunk4ZVKDHS6cjs.HOISTED_HEAD_ELEMENT.source}/i;
10236
10261
  let head = "";
10237
10262
  let body = markup;
10238
10263
  let match;
@@ -10868,7 +10893,7 @@ function createFarmAgentRobotsResponse(request) {
10868
10893
  // its nearest layout's.
10869
10894
  const farmAgentGuardedPages = new Set(${JSON.stringify(
10870
10895
  pageRoutes.map((route) => route.pattern).filter(
10871
- (pattern) => !pattern.includes("[") && _chunk4B6YJ5DScjs.farmPathGuardCoversPage.call(void 0,
10896
+ (pattern) => !pattern.includes("[") && _chunk4ZVKDHS6cjs.farmPathGuardCoversPage.call(void 0,
10872
10897
  {
10873
10898
  config: { middleware: config.middleware, integrations: config.integrations },
10874
10899
  middlewareRoutes
@@ -10923,7 +10948,7 @@ ${servesDefaultMCP ? `// agent.mcp: the default read-only MCP server at /mcp, as
10923
10948
  // aside for a page route that answers /mcp and for any MCP server published or
10924
10949
  // registered at runtime, such as the docs engine's.
10925
10950
  const farmDefaultMCPServer = ${JSON.stringify(
10926
- _chunkW53Z4WDIcjs.createFarmDefaultMCPServer.call(void 0, readFarmAppPackageIdentity(config.root), _chunk2NKNP4AHcjs.FARM_VERSION)
10951
+ _chunkW53Z4WDIcjs.createFarmDefaultMCPServer.call(void 0, readFarmAppPackageIdentity(config.root), _chunkHYL372GWcjs.FARM_VERSION)
10927
10952
  )};
10928
10953
  let farmDefaultMCPRouteFree;
10929
10954
  function getFarmDefaultMCPServer() {
@@ -11117,7 +11142,7 @@ ${edgeMiddlewareFilePaths.length > 0 ? `
11117
11142
  // middleware guards is never prerendered. Read once: Nitro's prerender worker sets the variable.
11118
11143
  const farmEdgeMiddlewareFiles = new Set(${JSON.stringify(edgeMiddlewareFilePaths)});
11119
11144
  const farmPrerendering =
11120
- typeof process !== "undefined" && process.env?.${_chunkBAD6T5NUcjs.FARM_PRERENDER_ENV} === "1";
11145
+ typeof process !== "undefined" && process.env?.${_chunk33WR5XV5cjs.FARM_PRERENDER_ENV} === "1";
11121
11146
  ` : ""}
11122
11147
  const farmMiddlewareRunner = ${hasMiddlewareRuntime ? `createProductionMiddlewareRunner({
11123
11148
  config: farmMiddlewareConfig,
@@ -11261,7 +11286,7 @@ function hasLocalRequestRoute(request, routePathname) {
11261
11286
  if (${imageRuntime === "none" ? "false" : `pathname === ${JSON.stringify(config.images.path)}`}) {
11262
11287
  return true;
11263
11288
  }
11264
- ${_optionalChain([config, 'access', _246 => _246.docs, 'optionalAccess', _247 => _247.enabled]) ? `const docsPath = normalizeRuntimePath(farmDocsResolvedConfig?.entry || "/docs");
11289
+ ${_optionalChain([config, 'access', _241 => _241.docs, 'optionalAccess', _242 => _242.enabled]) ? `const docsPath = normalizeRuntimePath(farmDocsResolvedConfig?.entry || "/docs");
11265
11290
  // The docs answer below the basePath; their API stays at /api/docs, as API routes do.
11266
11291
  const docsRoutePathname = stripFarmBasePath(pathname);
11267
11292
  if (
@@ -11289,7 +11314,7 @@ function getFarmPluginRequestOptions(request) {
11289
11314
  route: { ...route, pattern: normalizeRuntimePath(farmOpenAPIReference.route) },
11290
11315
  };
11291
11316
  }
11292
- const isDocsAPIRequest = ${_optionalChain([config, 'access', _248 => _248.docs, 'optionalAccess', _249 => _249.enabled]) ? "isFarmDocsAPIRequest(pathname)" : "false"};
11317
+ const isDocsAPIRequest = ${_optionalChain([config, 'access', _243 => _243.docs, 'optionalAccess', _244 => _244.enabled]) ? "isFarmDocsAPIRequest(pathname)" : "false"};
11293
11318
  const integrationMatch = ${hasServerRuntimeIntegrations ? `matchIntegrationRoute(serverRuntimeIntegrations, {
11294
11319
  pathname,
11295
11320
  method: request.method,
@@ -11373,7 +11398,7 @@ ${hasInfraAnalyticsRuntime ? `
11373
11398
  // endpoints, Markdown mirrors, and docs pages have no app route pattern, so they are
11374
11399
  // labeled here; route.pattern keeps meaning the matched app route for plugins.
11375
11400
  const farmBuiltInRoutePaths = new Set(${JSON.stringify(
11376
- _chunkTQJ35BBWcjs.listFarmBuiltInRoutePaths.call(void 0, {
11401
+ _chunkXFUPWRKTcjs.listFarmBuiltInRoutePaths.call(void 0, {
11377
11402
  agent: {
11378
11403
  ...config.agent,
11379
11404
  aiCatalog: servesAiCatalog,
@@ -11384,9 +11409,9 @@ const farmBuiltInRoutePaths = new Set(${JSON.stringify(
11384
11409
  openapi: openAPIReference
11385
11410
  })
11386
11411
  )});
11387
- ${_optionalChain([config, 'access', _250 => _250.docs, 'optionalAccess', _251 => _251.enabled]) ? `const farmDocsRouteLabelInput = {
11412
+ ${_optionalChain([config, 'access', _245 => _245.docs, 'optionalAccess', _246 => _246.enabled]) ? `const farmDocsRouteLabelInput = {
11388
11413
  path: normalizeRuntimePath(farmDocsResolvedConfig?.entry || "/docs"),
11389
- apiPath: ${JSON.stringify(_optionalChain([farmDocsPrecompiledManifest, 'optionalAccess', _252 => _252.apiPath]) || "/api/docs")},${_optionalChain([config, 'access', _253 => _253.docs, 'access', _254 => _254.roots, 'optionalAccess', _255 => _255.length]) ? "\n roots: farmDocsResolvedConfig.roots.map((farmDocsRoot) => farmDocsRoot.entry)," : ""}${farmDocsAnalyticsPages.length ? `
11414
+ apiPath: ${JSON.stringify(_optionalChain([farmDocsPrecompiledManifest, 'optionalAccess', _247 => _247.apiPath]) || "/api/docs")},${_optionalChain([config, 'access', _248 => _248.docs, 'access', _249 => _249.roots, 'optionalAccess', _250 => _250.length]) ? "\n roots: farmDocsResolvedConfig.roots.map((farmDocsRoot) => farmDocsRoot.entry)," : ""}${farmDocsAnalyticsPages.length ? `
11390
11415
  pages: new Set(${JSON.stringify(farmDocsAnalyticsPages)}),` : ""}
11391
11416
  };
11392
11417
  ` : ""}// The request's route payload, for a handler that learns what answered while it handles.
@@ -11402,11 +11427,11 @@ function labelFarmRequestOptions(options) {
11402
11427
  setFarmRouteLabel(options.route, mcpLabel);
11403
11428
  return options;
11404
11429
  }
11405
- ${_optionalChain([config, 'access', _256 => _256.docs, 'optionalAccess', _257 => _257.enabled]) ? `if (options.kind === "docs") {
11430
+ ${_optionalChain([config, 'access', _251 => _251.docs, 'optionalAccess', _252 => _252.enabled]) ? `if (options.kind === "docs") {
11406
11431
  setFarmRouteLabel(options.route, resolveFarmDocsRouteLabel(routePathname, farmDocsRouteLabelInput));
11407
11432
  return options;
11408
11433
  }` : ""}
11409
- ${_optionalChain([config, 'access', _258 => _258.md, 'optionalAccess', _259 => _259.enabled]) || hasMarkdownPages ? `const markdownLabel = resolveFarmMarkdownRouteLabel(
11434
+ ${_optionalChain([config, 'access', _253 => _253.md, 'optionalAccess', _254 => _254.enabled]) || hasMarkdownPages ? `const markdownLabel = resolveFarmMarkdownRouteLabel(
11410
11435
  routePathname,
11411
11436
  (page) => matchPageRoute(page)?.route.pattern,
11412
11437
  );
@@ -11441,7 +11466,7 @@ function getApplicableLayouts(pathname, directory) {
11441
11466
  return applicable;
11442
11467
  }
11443
11468
 
11444
- ${_optionalChain([config, 'access', _260 => _260.docs, 'optionalAccess', _261 => _261.enabled]) ? `async function wrapFarmDocsResponseWithLayouts(request, response) {
11469
+ ${_optionalChain([config, 'access', _255 => _255.docs, 'optionalAccess', _256 => _256.enabled]) ? `async function wrapFarmDocsResponseWithLayouts(request, response) {
11445
11470
  if (request.method === "HEAD") return response;
11446
11471
  if (response.headers.get("x-farm-docs-adapter")) return response;
11447
11472
 
@@ -11547,7 +11572,7 @@ ${_optionalChain([config, 'access', _260 => _260.docs, 'optionalAccess', _261 =>
11547
11572
 
11548
11573
  // Shells keep their own LRU so query-string variants never evict app cache entries.
11549
11574
  const pprShellCache = getFarmDataCache().pprShellCache;
11550
- const experimentalPPREnabled = ${JSON.stringify(_optionalChain([config, 'access', _262 => _262.experimental, 'optionalAccess', _263 => _263.ppr]) === true)};
11575
+ const experimentalPPREnabled = ${JSON.stringify(_optionalChain([config, 'access', _257 => _257.experimental, 'optionalAccess', _258 => _258.ppr]) === true)};
11551
11576
 
11552
11577
  function resolveRouteRenderingView(route) {
11553
11578
  // The same merge development uses: baked directive config under the
@@ -11667,7 +11692,7 @@ async function handleFarmRequest(request, adapterContext) {
11667
11692
  },
11668
11693
  { redirect: !isFarmLocalAPIPathname(requestUrl.pathname) }
11669
11694
  )` : "handleFarmRequestInContext(request, null, false, Date.now(), adapterContext, requestUrl)"};
11670
- ${_optionalChain([config, 'access', _264 => _264.md, 'optionalAccess', _265 => _265.enabled]) ? `const pathname = getFarmRoutePathname(requestUrl.pathname);
11695
+ ${_optionalChain([config, 'access', _259 => _259.md, 'optionalAccess', _260 => _260.enabled]) ? `const pathname = getFarmRoutePathname(requestUrl.pathname);
11671
11696
  if (matchPageRoute(pathname)) {
11672
11697
  // The Link header advertises the public .md URL, like the head alternate.
11673
11698
  return applyMarkdownNegotiationHeaders(response, {
@@ -11884,7 +11909,7 @@ ${hasServerRuntimeIntegrations ? `
11884
11909
  return renderFarmErrorJSONResponse();` : `
11885
11910
  if (isFarmLocalAPIPathname(pathname)) return renderFarmErrorJSONResponse();
11886
11911
  // No page was selected, so only the root error boundary and layouts apply.
11887
- const errorResponse = await renderFarmErrorResponse(middlewareResult.error, "/", {}, null);${_optionalChain([config, 'access', _266 => _266.md, 'optionalAccess', _267 => _267.enabled]) ? `
11912
+ const errorResponse = await renderFarmErrorResponse(middlewareResult.error, "/", {}, null);${_optionalChain([config, 'access', _261 => _261.md, 'optionalAccess', _262 => _262.enabled]) ? `
11888
11913
  // An agent asking for Markdown reads the error document as Markdown, as it
11889
11914
  // does when a page throws. The helper answers null when Markdown is off.
11890
11915
  const markdownErrorResponse = await createMarkdownMirrorResponse({
@@ -11926,7 +11951,7 @@ ${hasServerRuntimeIntegrations ? `
11926
11951
  }
11927
11952
  ` : ""}
11928
11953
 
11929
- ${_optionalChain([config, 'access', _268 => _268.docs, 'optionalAccess', _269 => _269.enabled]) ? `
11954
+ ${_optionalChain([config, 'access', _263 => _263.docs, 'optionalAccess', _264 => _264.enabled]) ? `
11930
11955
  // Docs responses are served after app middleware so route guards and
11931
11956
  // middleware headers apply to the docs engine like any other page content.
11932
11957
  // An app's own llms.txt, llms-full.txt, sitemap.xml, and robots.txt take
@@ -12042,7 +12067,7 @@ ${hasServerRuntimeIntegrations ? `
12042
12067
  }
12043
12068
  ` : ""}
12044
12069
 
12045
- ${_optionalChain([config, 'access', _270 => _270.md, 'optionalAccess', _271 => _271.enabled]) ? `
12070
+ ${_optionalChain([config, 'access', _265 => _265.md, 'optionalAccess', _266 => _266.enabled]) ? `
12046
12071
  if (farmMarkdownConfig?.enabled) {
12047
12072
  const markdownResponse = await createMarkdownMirrorResponse({
12048
12073
  // The mirror helper only reads metadata and creates its own GET request.
@@ -12146,11 +12171,11 @@ ${hasServerRuntimeIntegrations ? `
12146
12171
  return applyProductionMiddlewareHeaders(applicationMetadataResponse, middlewareHeaders);
12147
12172
  }
12148
12173
  ` : ""}
12149
- ${_optionalChain([config, 'access', _272 => _272.agent, 'optionalAccess', _273 => _273.manifest]) !== false ? `
12174
+ ${_optionalChain([config, 'access', _267 => _267.agent, 'optionalAccess', _268 => _268.manifest]) !== false ? `
12150
12175
  // agent.manifest: /.well-known/farmjs.json (and 0.1.34's /.well-known/farmjs), the app's
12151
12176
  // public manifest, the same document for every request.
12152
12177
  if (
12153
- [${JSON.stringify(_chunkTQJ35BBWcjs.FARM_APP_MANIFEST_PATH)}, ${JSON.stringify(_chunkTQJ35BBWcjs.FARM_APP_MANIFEST_LEGACY_PATH)}].includes(
12178
+ [${JSON.stringify(_chunkXFUPWRKTcjs.FARM_APP_MANIFEST_PATH)}, ${JSON.stringify(_chunkXFUPWRKTcjs.FARM_APP_MANIFEST_LEGACY_PATH)}].includes(
12154
12179
  normalizeRuntimePath(routePathname),
12155
12180
  )
12156
12181
  ) {
@@ -12160,9 +12185,9 @@ ${hasServerRuntimeIntegrations ? `
12160
12185
  );
12161
12186
  }
12162
12187
  ` : ""}
12163
- ${_optionalChain([config, 'access', _274 => _274.agent, 'optionalAccess', _275 => _275.apiCatalog]) ? `
12188
+ ${_optionalChain([config, 'access', _269 => _269.agent, 'optionalAccess', _270 => _270.apiCatalog]) ? `
12164
12189
  // agent.apiCatalog: list the OpenAPI and MCP surfaces at the RFC 9727 path.
12165
- if (normalizeRuntimePath(routePathname) === ${JSON.stringify(_chunkTQJ35BBWcjs.FARM_API_CATALOG_PATH)}) {
12190
+ if (normalizeRuntimePath(routePathname) === ${JSON.stringify(_chunkXFUPWRKTcjs.FARM_API_CATALOG_PATH)}) {
12166
12191
  return applyProductionMiddlewareHeaders(
12167
12192
  createFarmApiCatalogResponse(request.method, farmApiCatalogInput, request),
12168
12193
  middlewareHeaders,
@@ -12187,11 +12212,11 @@ ${hasServerRuntimeIntegrations ? `
12187
12212
  );
12188
12213
  }
12189
12214
  ` : ""}
12190
- ${_optionalChain([config, 'access', _276 => _276.agent, 'optionalAccess', _277 => _277.llmsTxt, 'optionalAccess', _278 => _278.enabled]) ? `
12215
+ ${_optionalChain([config, 'access', _271 => _271.agent, 'optionalAccess', _272 => _272.llmsTxt, 'optionalAccess', _273 => _273.enabled]) ? `
12191
12216
  // agent.llmsTxt with no llms.ts or llms-full.ts: serve the generated files.
12192
12217
  const farmGeneratedLlmsKind = normalizeRuntimePath(routePathname) === "/llms.txt"
12193
12218
  ? "llms"
12194
- : ${_optionalChain([config, 'access', _279 => _279.agent, 'optionalAccess', _280 => _280.llmsTxt, 'optionalAccess', _281 => _281.full]) ? `normalizeRuntimePath(routePathname) === "/llms-full.txt" ? "llms-full" : ` : ""}null;
12219
+ : ${_optionalChain([config, 'access', _274 => _274.agent, 'optionalAccess', _275 => _275.llmsTxt, 'optionalAccess', _276 => _276.full]) ? `normalizeRuntimePath(routePathname) === "/llms-full.txt" ? "llms-full" : ` : ""}null;
12195
12220
  if (farmGeneratedLlmsKind) {
12196
12221
  const llmsContext = createFarmLlmsTxtContext(request, farmGeneratedLlmsKind === "llms-full");
12197
12222
  // Renders are shared per origin the request reached, which is where pages are read.
@@ -12227,7 +12252,7 @@ ${hasServerRuntimeIntegrations ? `
12227
12252
  }
12228
12253
  ` : ""}
12229
12254
 
12230
- ${_optionalChain([config, 'access', _282 => _282.docs, 'optionalAccess', _283 => _283.enabled]) ? `if (farmDocsAPIHandler && isFarmDocsAPIRequest(pathname)) {
12255
+ ${_optionalChain([config, 'access', _277 => _277.docs, 'optionalAccess', _278 => _278.enabled]) ? `if (farmDocsAPIHandler && isFarmDocsAPIRequest(pathname)) {
12231
12256
  const docsAPIResponse = await farmDocsAPIHandler(cloneFarmRequestWithContext(request));
12232
12257
  if (docsAPIResponse) {
12233
12258
  return applyProductionMiddlewareHeaders(
@@ -12867,7 +12892,7 @@ ${hasServerRuntimeIntegrations ? `
12867
12892
  );
12868
12893
  }
12869
12894
  }
12870
- ${_optionalChain([config, 'access', _284 => _284.md, 'optionalAccess', _285 => _285.enabled]) ? `
12895
+ ${_optionalChain([config, 'access', _279 => _279.md, 'optionalAccess', _280 => _280.enabled]) ? `
12871
12896
  // Advertise the Markdown mirror in the head as well as the Link header,
12872
12897
  // using the public path the .md request will be resolved against.
12873
12898
  mergedMetadata = addMetadataMarkdownAlternate(
@@ -12896,7 +12921,7 @@ ${hasServerRuntimeIntegrations ? `
12896
12921
  emitFarmEvent({ type: "cache.bypass", route: pathname, reason: "cookie" });
12897
12922
  }
12898
12923
 
12899
- const renderedMetadata = renderMetadataHead(mergedMetadata, { pathname, jsonLd: ${JSON.stringify(_nullishCoalesce(_optionalChain([config, 'access', _286 => _286.agent, 'optionalAccess', _287 => _287.jsonLd]), () => ( false)))} });
12924
+ const renderedMetadata = renderMetadataHead(mergedMetadata, { pathname, jsonLd: ${JSON.stringify(_nullishCoalesce(_optionalChain([config, 'access', _281 => _281.agent, 'optionalAccess', _282 => _282.jsonLd]), () => ( false)))} });
12900
12925
  const title = renderedMetadata.title;
12901
12926
  const metaTags = renderedMetadata.tags;
12902
12927
  const hasFavicon = renderedMetadata.hasFavicon;
@@ -13741,11 +13766,11 @@ function createFarmRuntimeHookErrorResponse(request, error) {
13741
13766
  export async function fetch(request, context) {${imageRuntime === "none" ? "" : `
13742
13767
  // The image optimizer's fetch of a local source is not a loopback visitor.
13743
13768
  context = _withFarmImageSourceClientAddress(request, context);`}
13744
- ${_optionalChain([config, 'access', _288 => _288.agent, 'optionalAccess', _289 => _289.noindexPreviews]) ? "const response = await" : "return"} _runWithAPIRequestRuntime({
13769
+ ${_optionalChain([config, 'access', _283 => _283.agent, 'optionalAccess', _284 => _284.noindexPreviews]) ? "const response = await" : "return"} _runWithAPIRequestRuntime({
13745
13770
  basePath: farmLocalAPIBasePath,
13746
13771
  dispatch: async (localRequest) =>
13747
13772
  (await handleAPIRequest(localRequest)) ?? Response.json({ error: "Not Found" }, { status: 404 }),
13748
- }, () => handleFarmFetch(request, context));${_optionalChain([config, 'access', _290 => _290.agent, 'optionalAccess', _291 => _291.noindexPreviews]) ? `
13773
+ }, () => handleFarmFetch(request, context));${_optionalChain([config, 'access', _285 => _285.agent, 'optionalAccess', _286 => _286.noindexPreviews]) ? `
13749
13774
  // Keep every response of a preview deployment out of search indexes.
13750
13775
  return farmNoindexPreview ? applyFarmPreviewRobotsTag(response) : response;` : ""}
13751
13776
  }
@@ -13955,7 +13980,7 @@ function getManifestPageEntry(manifest, pathname) {
13955
13980
  })).sort((left, right) => _chunkML4TOUZPcjs.compareRouteSpecificity.call(void 0, left.specificity, right.specificity)).map(({ entry, matches }) => ({ entry, matches }));
13956
13981
  manifestPageMatchers.set(manifest.routes, pages);
13957
13982
  }
13958
- return _optionalChain([pages, 'access', _292 => _292.find, 'call', _293 => _293((page) => page.matches(pathname)), 'optionalAccess', _294 => _294.entry]);
13983
+ return _optionalChain([pages, 'access', _287 => _287.find, 'call', _288 => _288((page) => page.matches(pathname)), 'optionalAccess', _289 => _289.entry]);
13959
13984
  }
13960
13985
  function withFarmEdgeGuardedPrerenderHeaders(headers, edgeGuarded) {
13961
13986
  if (!edgeGuarded) return headers;
@@ -13992,13 +14017,13 @@ function getPhysicalPrerenderBypassReason(options) {
13992
14017
  if (rewriteSources.some((source) => middlewarePatternMatches(source, pathname))) {
13993
14018
  return "rewrite";
13994
14019
  }
13995
- if (_chunk4B6YJ5DScjs.appMiddlewareMayHandlePath.call(void 0, middlewareRoutes, pathname)) return "app middleware";
13996
- if (_chunk4B6YJ5DScjs.configMiddlewareMayHandlePath.call(void 0, config.middleware, pathname)) return "configured middleware";
13997
- if (_chunkFDU4Q4QPcjs.hasCustomFarmRouteContext.call(void 0, config)) return "request context";
14020
+ if (_chunk4ZVKDHS6cjs.appMiddlewareMayHandlePath.call(void 0, middlewareRoutes, pathname)) return "app middleware";
14021
+ if (_chunk4ZVKDHS6cjs.configMiddlewareMayHandlePath.call(void 0, config.middleware, pathname)) return "configured middleware";
14022
+ if (_chunkMZR22RACcjs.hasCustomFarmRouteContext.call(void 0, config)) return "request context";
13998
14023
  if (farmServerRuntimePluginsMayHandlePath(config, pathname)) return "server runtime plugin";
13999
14024
  const manifestEntry = getManifestPageEntry(routeRuntimeManifest, pathname);
14000
- if (_optionalChain([manifestEntry, 'optionalAccess', _295 => _295.rendering]) === "dynamic") return "dynamic runtime manifest";
14001
- if (manifestEntry && (manifestEntry.runtime !== "auto" || Boolean(_optionalChain([manifestEntry, 'access', _296 => _296.regions, 'optionalAccess', _297 => _297.length])) || manifestEntry.maxDuration !== void 0)) {
14025
+ if (_optionalChain([manifestEntry, 'optionalAccess', _290 => _290.rendering]) === "dynamic") return "dynamic runtime manifest";
14026
+ if (manifestEntry && (manifestEntry.runtime !== "auto" || Boolean(_optionalChain([manifestEntry, 'access', _291 => _291.regions, 'optionalAccess', _292 => _292.length])) || manifestEntry.maxDuration !== void 0)) {
14002
14027
  return "route runtime controls";
14003
14028
  }
14004
14029
  const routeRule = getEffectiveRouteRule(config, pathname);
@@ -14011,7 +14036,7 @@ function getPhysicalPrerenderBypassReason(options) {
14011
14036
  return void 0;
14012
14037
  }
14013
14038
  async function getFarmDocsPrerenderPages(config, root, preset) {
14014
- if (!_optionalChain([config, 'access', _298 => _298.docs, 'optionalAccess', _299 => _299.enabled]) || !config.docs.prerender) return [];
14039
+ if (!_optionalChain([config, 'access', _293 => _293.docs, 'optionalAccess', _294 => _294.enabled]) || !config.docs.prerender) return [];
14015
14040
  if (_chunkNLBHLPEOcjs.getFarmPresetRuntime.call(void 0, preset) === "edge") {
14016
14041
  _chunk7U4XF76Rcjs.logger.info(
14017
14042
  `\u21AA Keeping docs pages in the edge docs snapshot: docs.prerender writes static files on Node and serverless targets, not "${preset}".`
@@ -14030,7 +14055,7 @@ async function getFarmDocsPrerenderPages(config, root, preset) {
14030
14055
  }
14031
14056
  return pages2;
14032
14057
  }
14033
- const pages = await _chunkBLZCAFGJcjs.listFarmDocsAdapterPages.call(void 0, config.docs, { root, srcDir: config.srcDir });
14058
+ const pages = await _chunkCXHVRHM2cjs.listFarmDocsAdapterPages.call(void 0, config.docs, { root, srcDir: config.srcDir });
14034
14059
  if (!pages) {
14035
14060
  _chunk7U4XF76Rcjs.logger.warn(
14036
14061
  `The docs adapter ${JSON.stringify(config.docs.adapter.id)} does not list its pages for prerendering; upgrade it to prerender docs pages. They render on request until then.`
@@ -14040,11 +14065,11 @@ async function getFarmDocsPrerenderPages(config, root, preset) {
14040
14065
  return pages;
14041
14066
  }
14042
14067
  async function listFarmDocsAnalyticsPages(config, root, preset) {
14043
- if (!_optionalChain([config, 'access', _300 => _300.docs, 'optionalAccess', _301 => _301.enabled]) || config.analytics === false || _chunkOCS3PSYRcjs.resolveFarmInstrumentationRuntime.call(void 0, preset) !== "nodejs") {
14068
+ if (!_optionalChain([config, 'access', _295 => _295.docs, 'optionalAccess', _296 => _296.enabled]) || config.analytics === false || _chunkOCS3PSYRcjs.resolveFarmInstrumentationRuntime.call(void 0, preset) !== "nodejs") {
14044
14069
  return [];
14045
14070
  }
14046
14071
  try {
14047
- return await _chunkBLZCAFGJcjs.listFarmDocsPagePaths.call(void 0, config.docs, {
14072
+ return await _chunkCXHVRHM2cjs.listFarmDocsPagePaths.call(void 0, config.docs, {
14048
14073
  root,
14049
14074
  srcDir: config.srcDir,
14050
14075
  adapter: _chunkL2GUEYHRcjs.hasFarmDocsRuntimeAdapter.call(void 0, config.docs)
@@ -14058,9 +14083,9 @@ async function listFarmDocsAnalyticsPages(config, root, preset) {
14058
14083
  }
14059
14084
  function hasFarmNitroCacheRouteRule(routeRules) {
14060
14085
  return Object.values(routeRules || {}).some((rule) => {
14061
- const swr = _optionalChain([rule, 'optionalAccess', _302 => _302.swr]);
14062
- const cache = _optionalChain([rule, 'optionalAccess', _303 => _303.cache]);
14063
- const headers = _optionalChain([rule, 'optionalAccess', _304 => _304.headers]);
14086
+ const swr = _optionalChain([rule, 'optionalAccess', _297 => _297.swr]);
14087
+ const cache = _optionalChain([rule, 'optionalAccess', _298 => _298.cache]);
14088
+ const headers = _optionalChain([rule, 'optionalAccess', _299 => _299.headers]);
14064
14089
  return swr !== void 0 && swr !== false || cache !== void 0 && cache !== false || !!headers && typeof headers === "object" && Object.keys(headers).length > 0;
14065
14090
  });
14066
14091
  }
@@ -14073,10 +14098,10 @@ async function buildNitroUniversal(config, routeManager, apiRouteManager, server
14073
14098
  const nitroBuilder = nitroBuilderResult.value;
14074
14099
  const isVercel = preset === "vercel";
14075
14100
  const isCloudflareWorker = preset === "cloudflare-module";
14076
- const outputDir = _chunkFDU4Q4QPcjs.resolveDeployOutputPath.call(void 0, root, config.deploy.outputDir);
14101
+ const outputDir = _chunkMZR22RACcjs.resolveDeployOutputPath.call(void 0, root, config.deploy.outputDir);
14077
14102
  const runtimeServerOutputDir = isVercel ? _path2.default.join(outputDir, "functions", "__nitro.func") : _path2.default.join(outputDir, "server");
14078
14103
  const ssrOutputDir = _path2.default.join(root, distDir, "ssr");
14079
- const imageRuntime = _chunkP253SZJFcjs.resolveFarmImageServerRuntime.call(void 0, config.images, preset);
14104
+ const imageRuntime = _chunkTI4BZV6Mcjs.resolveFarmImageServerRuntime.call(void 0, config.images, preset);
14080
14105
  const hasGeneratedMetadataImages = Array.from(routeManager.getMetadataImages().values()).some(
14081
14106
  (image) => image.sourceType === "module"
14082
14107
  );
@@ -14132,7 +14157,7 @@ async function buildNitroUniversal(config, routeManager, apiRouteManager, server
14132
14157
  const edgeGuardedPrerenderRoutes = [];
14133
14158
  const addPrerenderRoute = (pathname) => {
14134
14159
  prerenderRoutes.push(pathname);
14135
- if (_chunk4B6YJ5DScjs.appMiddlewareMayHandlePath.call(void 0, edgeMiddlewareRoutes, pathname)) {
14160
+ if (_chunk4ZVKDHS6cjs.appMiddlewareMayHandlePath.call(void 0, edgeMiddlewareRoutes, pathname)) {
14136
14161
  edgeGuardedPrerenderRoutes.push(pathname);
14137
14162
  }
14138
14163
  };
@@ -14226,7 +14251,7 @@ async function buildNitroUniversal(config, routeManager, apiRouteManager, server
14226
14251
  webEntry: clientJsSrc,
14227
14252
  webBoot: clientBootSrc,
14228
14253
  stylesheet: clientCssHref,
14229
- webFiles: _nullishCoalesce(_optionalChain([clientModulePreloads, 'optionalAccess', _305 => _305.files]), () => ( []))
14254
+ webFiles: _nullishCoalesce(_optionalChain([clientModulePreloads, 'optionalAccess', _300 => _300.files]), () => ( []))
14230
14255
  })
14231
14256
  ) : null;
14232
14257
  for (const output of Object.values(ssrBundle)) {
@@ -14552,7 +14577,7 @@ function toFarmNodeResponse(request, response) {
14552
14577
  varyFarmNitroCacheRules(_chunkIIHZ2BEEcjs.routeRulesToNitroRouteRules.call(void 0, config.routeRules), [
14553
14578
  ...config.md.enabled ? ["accept"] : [],
14554
14579
  ...shouldBuildFarmMobileClient(config) ? ["x-farm-shell"] : [],
14555
- ..._chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _306 => _306.experimental, 'optionalAccess', _307 => _307.serverComponents])) === "islands" ? ["f-layouts"] : []
14580
+ ..._chunkT7UC2ORAcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([config, 'access', _301 => _301.experimental, 'optionalAccess', _302 => _302.serverComponents])) === "islands" ? ["f-layouts"] : []
14556
14581
  ]),
14557
14582
  config.basePath,
14558
14583
  _chunk2OF5RPVUcjs.resolveFarmAPIServerBasePath.call(void 0, config.api)
@@ -14717,22 +14742,22 @@ function toFarmNodeResponse(request, response) {
14717
14742
  snapshotSSRRebundleOptions(nitroConfig)
14718
14743
  );
14719
14744
  const requestedBuilder = _nullishCoalesce(nitroConfig.builder, () => ( process.env.NITRO_BUILDER));
14720
- const nitroBuildIsFarms = (requestedBuilder === void 0 || requestedBuilder === "rollup" || requestedBuilder === "rolldown") && nitroConfig.sourcemap === false && !hasCustomOxcOptions && !hasLateBuildMutationConfig && !hasUnsupportedSSRRebundleOverrides && _optionalChain([nitroConfig, 'access', _308 => _308.rollupConfig, 'optionalAccess', _309 => _309.external]) === nitroRollupExternal && !hasRollupPlugins(_optionalChain([nitroConfig, 'access', _310 => _310.rollupConfig, 'optionalAccess', _311 => _311.plugins])) && customRollupKeys.length === 0 && Boolean(
14721
- _optionalChain([nitroConfig, 'access', _312 => _312.handlers, 'optionalAccess', _313 => _313.some, 'call', _314 => _314(
14722
- (handler) => _path2.default.resolve(_optionalChain([handler, 'optionalAccess', _315 => _315.handler]) || "") === nitroEntryPath
14745
+ const nitroBuildIsFarms = (requestedBuilder === void 0 || requestedBuilder === "rollup" || requestedBuilder === "rolldown") && nitroConfig.sourcemap === false && !hasCustomOxcOptions && !hasLateBuildMutationConfig && !hasUnsupportedSSRRebundleOverrides && _optionalChain([nitroConfig, 'access', _303 => _303.rollupConfig, 'optionalAccess', _304 => _304.external]) === nitroRollupExternal && !hasRollupPlugins(_optionalChain([nitroConfig, 'access', _305 => _305.rollupConfig, 'optionalAccess', _306 => _306.plugins])) && customRollupKeys.length === 0 && Boolean(
14746
+ _optionalChain([nitroConfig, 'access', _307 => _307.handlers, 'optionalAccess', _308 => _308.some, 'call', _309 => _309(
14747
+ (handler) => _path2.default.resolve(_optionalChain([handler, 'optionalAccess', _310 => _310.handler]) || "") === nitroEntryPath
14723
14748
  )])
14724
14749
  );
14725
- const canReusePrebuiltSSR = isPrebuiltSSRCandidate && nitroConfig.preset === "node-server" && nitroBuildIsFarms && _path2.default.resolve(_optionalChain([nitroConfig, 'access', _316 => _316.output, 'optionalAccess', _317 => _317.serverDir]) || "") === _path2.default.resolve(expectedServerDir);
14750
+ const canReusePrebuiltSSR = isPrebuiltSSRCandidate && nitroConfig.preset === "node-server" && nitroBuildIsFarms && _path2.default.resolve(_optionalChain([nitroConfig, 'access', _311 => _311.output, 'optionalAccess', _312 => _312.serverDir]) || "") === _path2.default.resolve(expectedServerDir);
14726
14751
  const prerenderReusesPrebuiltSSR = prerenderRoutes.length > 0 && ssrExternalsArePackaged && nitroBuildIsFarms;
14727
14752
  const selectRolldownBuilder = canReusePrebuiltSSR && requestedBuilder === void 0 && await canUseRolldownBuilder();
14728
14753
  if (selectRolldownBuilder) nitroConfig.builder = "rolldown";
14729
14754
  const useRolldownBuilder = canReusePrebuiltSSR && (_nullishCoalesce(nitroConfig.builder, () => ( process.env.NITRO_BUILDER))) === "rolldown";
14730
14755
  const shouldMinify = nitroConfig.minify !== false;
14731
- const keepServerNames = !(_optionalChain([config, 'access', _318 => _318.docs, 'optionalAccess', _319 => _319.enabled]) && _optionalChain([config, 'access', _320 => _320.docs, 'access', _321 => _321.adapter, 'optionalAccess', _322 => _322.server]));
14756
+ const keepServerNames = !(_optionalChain([config, 'access', _313 => _313.docs, 'optionalAccess', _314 => _314.enabled]) && _optionalChain([config, 'access', _315 => _315.docs, 'access', _316 => _316.adapter, 'optionalAccess', _317 => _317.server]));
14732
14757
  const useFarmServerMinifier = shouldMinify && nitroConfig.sourcemap === false && !hasCustomOxcOptions && !hasLateBuildMutationConfig;
14733
14758
  const serverChunkMinifier = useFarmServerMinifier ? createServerChunkMinifyPlugin({ keepNames: keepServerNames, target: "esnext" }) : null;
14734
14759
  const ssrRollupPlugin = canReusePrebuiltSSR ? prebuiltSSRPlugin : createServerReadSSRAssetsPlugin(ssrBundle, ssrOutputDir);
14735
- const configuredRollupPlugins = _optionalChain([nitroConfig, 'access', _323 => _323.rollupConfig, 'optionalAccess', _324 => _324.plugins]);
14760
+ const configuredRollupPlugins = _optionalChain([nitroConfig, 'access', _318 => _318.rollupConfig, 'optionalAccess', _319 => _319.plugins]);
14736
14761
  nitroConfig.rollupConfig = {
14737
14762
  ...nitroConfig.rollupConfig,
14738
14763
  plugins: [
@@ -14771,7 +14796,7 @@ function toFarmNodeResponse(request, response) {
14771
14796
  let skippedNonHtmlPrerenderRoute = false;
14772
14797
  nitroInstance.hooks.hook("prerender:generate", (route) => {
14773
14798
  if (route.error || !prerenderPagePaths.has(route.route)) return;
14774
- if (_optionalChain([route, 'access', _325 => _325.contentType, 'optionalAccess', _326 => _326.toLowerCase, 'call', _327 => _327(), 'access', _328 => _328.includes, 'call', _329 => _329("html")])) return;
14799
+ if (_optionalChain([route, 'access', _320 => _320.contentType, 'optionalAccess', _321 => _321.toLowerCase, 'call', _322 => _322(), 'access', _323 => _323.includes, 'call', _324 => _324("html")])) return;
14775
14800
  route.skip = true;
14776
14801
  skippedNonHtmlPrerenderRoute = true;
14777
14802
  const configuredRule = configuredNitroRouteRules[route.route];
@@ -14782,9 +14807,9 @@ function toFarmNodeResponse(request, response) {
14782
14807
  nitroInstance.hooks.hook("prerender:done", () => {
14783
14808
  if (skippedNonHtmlPrerenderRoute) nitroInstance.routing.sync();
14784
14809
  });
14785
- if (_optionalChain([config, 'access', _330 => _330.md, 'optionalAccess', _331 => _331.enabled])) {
14810
+ if (_optionalChain([config, 'access', _325 => _325.md, 'optionalAccess', _326 => _326.enabled])) {
14786
14811
  nitroInstance.hooks.hook("prerender:generate", (route) => {
14787
- if (!route.contents || !_optionalChain([route, 'access', _332 => _332.contentType, 'optionalAccess', _333 => _333.toLowerCase, 'call', _334 => _334(), 'access', _335 => _335.includes, 'call', _336 => _336("html")])) return;
14812
+ if (!route.contents || !_optionalChain([route, 'access', _327 => _327.contentType, 'optionalAccess', _328 => _328.toLowerCase, 'call', _329 => _329(), 'access', _330 => _330.includes, 'call', _331 => _331("html")])) return;
14788
14813
  const alternatePath = _chunk2NOHVIJ3cjs.getFarmMarkdownAlternatePath.call(void 0, config.md, route.route, {
14789
14814
  routePathname: (pathname) => routeManager.toRoutePathname(pathname)
14790
14815
  });
@@ -14807,7 +14832,7 @@ function toFarmNodeResponse(request, response) {
14807
14832
  }
14808
14833
  if (config.security.csp && config.security.csp.nonce) {
14809
14834
  nitroInstance.hooks.hook("prerender:generate", async (route) => {
14810
- if (!route.contents || !_optionalChain([route, 'access', _337 => _337.contentType, 'optionalAccess', _338 => _338.toLowerCase, 'call', _339 => _339(), 'access', _340 => _340.includes, 'call', _341 => _341("html")])) return;
14835
+ if (!route.contents || !_optionalChain([route, 'access', _332 => _332.contentType, 'optionalAccess', _333 => _333.toLowerCase, 'call', _334 => _334(), 'access', _335 => _335.includes, 'call', _336 => _336("html")])) return;
14811
14836
  const staticCsp = await _chunk6JHZPB52cjs.applyFarmCspHashesToHtml.call(void 0, route.contents, config.security);
14812
14837
  if (!staticCsp) return;
14813
14838
  route.contents = staticCsp.html;
@@ -14843,7 +14868,7 @@ function toFarmNodeResponse(request, response) {
14843
14868
  await nitroBuilder.copyPublicAssets(nitroInstance);
14844
14869
  if (prerenderReusesPrebuiltSSR && !canReusePrebuiltSSR) {
14845
14870
  nitroInstance.hooks.hook("prerender:config", (prerendererConfig) => {
14846
- const configuredPlugins = _optionalChain([prerendererConfig, 'access', _342 => _342.rollupConfig, 'optionalAccess', _343 => _343.plugins]);
14871
+ const configuredPlugins = _optionalChain([prerendererConfig, 'access', _337 => _337.rollupConfig, 'optionalAccess', _338 => _338.plugins]);
14847
14872
  const plugins = Array.isArray(configuredPlugins) ? configuredPlugins : configuredPlugins ? [configuredPlugins] : [];
14848
14873
  prerendererConfig.rollupConfig = {
14849
14874
  ...prerendererConfig.rollupConfig,
@@ -14900,13 +14925,13 @@ function toFarmNodeResponse(request, response) {
14900
14925
  }
14901
14926
  if (prerenderRoutes.length > 0) {
14902
14927
  _chunk7U4XF76Rcjs.logger.info(`\u{1F4C4} Pre-rendering ${prerenderRoutes.length} SSG page(s)`);
14903
- const previousPrerender = process.env[_chunkBAD6T5NUcjs.FARM_PRERENDER_ENV];
14904
- process.env[_chunkBAD6T5NUcjs.FARM_PRERENDER_ENV] = "1";
14928
+ const previousPrerender = process.env[_chunk33WR5XV5cjs.FARM_PRERENDER_ENV];
14929
+ process.env[_chunk33WR5XV5cjs.FARM_PRERENDER_ENV] = "1";
14905
14930
  try {
14906
14931
  await nitroBuilder.prerender(nitroInstance);
14907
14932
  } finally {
14908
- if (previousPrerender === void 0) delete process.env[_chunkBAD6T5NUcjs.FARM_PRERENDER_ENV];
14909
- else process.env[_chunkBAD6T5NUcjs.FARM_PRERENDER_ENV] = previousPrerender;
14933
+ if (previousPrerender === void 0) delete process.env[_chunk33WR5XV5cjs.FARM_PRERENDER_ENV];
14934
+ else process.env[_chunk33WR5XV5cjs.FARM_PRERENDER_ENV] = previousPrerender;
14910
14935
  }
14911
14936
  }
14912
14937
  const sharpRuntimeStagePromise = imageRuntime === "node" ? stageSharpRuntime(config, root, distDir, fs5, preset) : Promise.resolve(null);
@@ -15083,7 +15108,7 @@ async function moveVercelOutputPath(src, dest, fs5) {
15083
15108
  await fs5.rename(src, dest);
15084
15109
  return;
15085
15110
  } catch (error) {
15086
- const code = _optionalChain([error, 'optionalAccess', _344 => _344.code]);
15111
+ const code = _optionalChain([error, 'optionalAccess', _339 => _339.code]);
15087
15112
  if (code !== "EPERM" && code !== "EACCES" && code !== "EXDEV" && code !== "ENOTEMPTY") {
15088
15113
  throw error;
15089
15114
  }
@@ -15109,7 +15134,7 @@ async function postProcessVercelOutput(root, outputDir, fs5, config, farmWorkflo
15109
15134
  try {
15110
15135
  await moveVercelOutputPath(publicDir, staticDir, fs5);
15111
15136
  } catch (error) {
15112
- if (_optionalChain([error, 'optionalAccess', _345 => _345.code]) !== "ENOENT") throw error;
15137
+ if (_optionalChain([error, 'optionalAccess', _340 => _340.code]) !== "ENOENT") throw error;
15113
15138
  }
15114
15139
  await copyFarmDocsContentForVercel(config, root, nitroFuncDir, fs5);
15115
15140
  await copyPrismaClientForVercel(root, nitroFuncDir, fs5);
@@ -15123,7 +15148,7 @@ async function postProcessVercelOutput(root, outputDir, fs5, config, farmWorkflo
15123
15148
  config.basePath
15124
15149
  );
15125
15150
  const edgeMiddlewareRoutes = edgeMiddleware.middlewareRoutes.filter(
15126
- (route) => edgeMiddleware.guardedPages.some((pathname) => _chunk4B6YJ5DScjs.appMiddlewareMayHandlePath.call(void 0, [route], pathname))
15151
+ (route) => edgeMiddleware.guardedPages.some((pathname) => _chunk4ZVKDHS6cjs.appMiddlewareMayHandlePath.call(void 0, [route], pathname))
15127
15152
  );
15128
15153
  if (edgeMiddlewareRoutes.length > 0) {
15129
15154
  await writeFarmVercelEdgeMiddlewareFunction({
@@ -15151,7 +15176,7 @@ async function postProcessVercelOutput(root, outputDir, fs5, config, farmWorkflo
15151
15176
  _chunk7U4XF76Rcjs.logger.info("\u2705 Post-processed Vercel output for Build Output API v3");
15152
15177
  }
15153
15178
  async function copyFarmDocsContentForVercel(config, root, nitroFuncDir, fs5) {
15154
- if (!_optionalChain([config, 'access', _346 => _346.docs, 'optionalAccess', _347 => _347.enabled])) return;
15179
+ if (!_optionalChain([config, 'access', _341 => _341.docs, 'optionalAccess', _342 => _342.enabled])) return;
15155
15180
  const [mainRoot, ...extraRoots] = _chunkHR5GU4UUcjs.getFarmDocsRoots.call(void 0, config.docs);
15156
15181
  await copyFarmDocsRootContent(
15157
15182
  mainRoot,
@@ -15176,7 +15201,7 @@ async function copyFarmDocsRootContent(docs, root, srcDir, bundledContentDir, fs
15176
15201
  const lastModifiedManifest = _chunkHR5GU4UUcjs.createFarmDocsLastModifiedManifest.call(void 0, docsContentDir, {
15177
15202
  fallback: "now"
15178
15203
  });
15179
- const undatedPages = _nullishCoalesce(_optionalChain([lastModifiedManifest, 'access', _348 => _348.unknown, 'optionalAccess', _349 => _349.length]), () => ( 0));
15204
+ const undatedPages = _nullishCoalesce(_optionalChain([lastModifiedManifest, 'access', _343 => _343.unknown, 'optionalAccess', _344 => _344.length]), () => ( 0));
15180
15205
  if (undatedPages > 0) {
15181
15206
  _chunk7U4XF76Rcjs.logger.warn(
15182
15207
  `${undatedPages} docs page(s) were last changed before this shallow clone's Git history, so they show no "Last updated" date. Build from a full clone (git fetch --unshallow) or set lastModified in the page's frontmatter.`
@@ -15261,7 +15286,7 @@ async function stageSharpRuntime(config, root, distDir, fs5, preset) {
15261
15286
  try {
15262
15287
  await copyPackage("sharp", sharpRequire);
15263
15288
  if (!copiedPackages.has("sharp")) {
15264
- throw new Error(`Farm image optimization requires sharp. ${_chunkP253SZJFcjs.SHARP_INSTALL_HINT}`);
15289
+ throw new Error(`Farm image optimization requires sharp. ${_chunkTI4BZV6Mcjs.SHARP_INSTALL_HINT}`);
15265
15290
  }
15266
15291
  } catch (error) {
15267
15292
  await fs5.rm(stageDir, { recursive: true, force: true });
@@ -15494,7 +15519,7 @@ async function createFarmProjectModuleSsrEnvironment() {
15494
15519
  // src/build/index.ts
15495
15520
  async function build(config, options = {}) {
15496
15521
  return _chunkNG2EZ6QScjs.withProductionNodeEnv.call(void 0,
15497
- () => _chunkQYDGIXQ5cjs.withPackageClientBoundaryCache.call(void 0, () => buildWithProductionNodeEnv(config, options))
15522
+ () => _chunkU3A46QFDcjs.withPackageClientBoundaryCache.call(void 0, () => buildWithProductionNodeEnv(config, options))
15498
15523
  );
15499
15524
  }
15500
15525
  function createBuildTargetBaseline(config) {
@@ -15505,7 +15530,7 @@ function createBuildTargetBaseline(config) {
15505
15530
  preset,
15506
15531
  distDir,
15507
15532
  outputDir,
15508
- outputWasDerived: outputDir === _chunkFDU4Q4QPcjs.getDefaultDeployOutputDir.call(void 0, config.deploy.target, preset, distDir)
15533
+ outputWasDerived: outputDir === _chunkMZR22RACcjs.getDefaultDeployOutputDir.call(void 0, config.deploy.target, preset, distDir)
15509
15534
  };
15510
15535
  }
15511
15536
  function resolveBuildTargets(config, options, baseline) {
@@ -15514,8 +15539,8 @@ function resolveBuildTargets(config, options, baseline) {
15514
15539
  const distDir = config.distDir || ".farm";
15515
15540
  const outputWasReplaced = config.deploy.outputDir !== baseline.outputDir;
15516
15541
  const shouldRefreshDerivedOutput = baseline.outputWasDerived && !outputWasReplaced && (preset !== baseline.preset || distDir !== baseline.distDir);
15517
- const deployTarget = preset === config.deploy.preset ? config.deploy.target : _chunkFDU4Q4QPcjs.getDeployTargetForPreset.call(void 0, preset);
15518
- const outputDir = shouldRefreshDerivedOutput ? _chunkFDU4Q4QPcjs.getDefaultDeployOutputDir.call(void 0, deployTarget, preset, distDir) : config.deploy.outputDir;
15542
+ const deployTarget = preset === config.deploy.preset ? config.deploy.target : _chunkMZR22RACcjs.getDeployTargetForPreset.call(void 0, preset);
15543
+ const outputDir = shouldRefreshDerivedOutput ? _chunkMZR22RACcjs.getDefaultDeployOutputDir.call(void 0, deployTarget, preset, distDir) : config.deploy.outputDir;
15519
15544
  return {
15520
15545
  root,
15521
15546
  preset,
@@ -15523,7 +15548,7 @@ function resolveBuildTargets(config, options, baseline) {
15523
15548
  distDir,
15524
15549
  deployTarget,
15525
15550
  outputDir,
15526
- deployOutputDir: _chunkFDU4Q4QPcjs.resolveDeployOutputPath.call(void 0, root, outputDir)
15551
+ deployOutputDir: _chunkMZR22RACcjs.resolveDeployOutputPath.call(void 0, root, outputDir)
15527
15552
  };
15528
15553
  }
15529
15554
  async function buildWithProductionNodeEnv(inputConfig, options) {
@@ -15560,15 +15585,15 @@ async function buildWithProductionNodeEnv(inputConfig, options) {
15560
15585
  };
15561
15586
  config = {
15562
15587
  ...config,
15563
- images: _chunkP253SZJFcjs.resolveFarmImageProviderForRuntime.call(void 0, config.images, {
15588
+ images: _chunkTI4BZV6Mcjs.resolveFarmImageProviderForRuntime.call(void 0, config.images, {
15564
15589
  root: targets.root,
15565
15590
  preset: targets.preset
15566
15591
  })
15567
15592
  };
15568
- if (_optionalChain([config, 'access', _350 => _350.docs, 'optionalAccess', _351 => _351.enabled])) await _chunkNDOE76QCcjs.loadFarmDocsEngine.call(void 0, );
15593
+ if (_optionalChain([config, 'access', _345 => _345.docs, 'optionalAccess', _346 => _346.enabled])) await _chunkNDOE76QCcjs.loadFarmDocsEngine.call(void 0, );
15569
15594
  pluginManager.updateContext({ config });
15570
15595
  const { root, preset, srcDir, distDir, deployOutputDir } = targets;
15571
- _chunkQYDGIXQ5cjs.usePackageClientBoundaryCacheFile.call(void 0, _chunkQYDGIXQ5cjs.resolvePackageClientBoundaryCacheFile.call(void 0, root, distDir));
15596
+ _chunkU3A46QFDcjs.usePackageClientBoundaryCacheFile.call(void 0, _chunkU3A46QFDcjs.resolvePackageClientBoundaryCacheFile.call(void 0, root, distDir));
15572
15597
  _chunk7U4XF76Rcjs.logger.info(`\u{1F69C} Building Farm.js application with preset: ${preset}...`);
15573
15598
  await pluginManager.setupPlugins();
15574
15599
  await pluginManager.runHookParallel("beforeBundle", {
@@ -15580,8 +15605,8 @@ async function buildWithProductionNodeEnv(inputConfig, options) {
15580
15605
  });
15581
15606
  _chunk7U4XF76Rcjs.logger.info("\u{1F50D} Discovering routes and API endpoints...");
15582
15607
  const productionViteResult = productionViteResultPromise ? (await productionViteResultPromise)[0] : void 0;
15583
- if (_optionalChain([productionViteResult, 'optionalAccess', _352 => _352.status]) === "rejected") throw productionViteResult.reason;
15584
- const productionVite = _optionalChain([productionViteResult, 'optionalAccess', _353 => _353.value]);
15608
+ if (_optionalChain([productionViteResult, 'optionalAccess', _347 => _347.status]) === "rejected") throw productionViteResult.reason;
15609
+ const productionVite = _optionalChain([productionViteResult, 'optionalAccess', _348 => _348.value]);
15585
15610
  const createViteServer = productionVite ? productionVite.createServer : (await import("vite")).createServer;
15586
15611
  projectModuleServer = await createProjectModuleServer(
15587
15612
  createViteServer,
@@ -15589,7 +15614,7 @@ async function buildWithProductionNodeEnv(inputConfig, options) {
15589
15614
  root,
15590
15615
  rendererBuild.signal
15591
15616
  );
15592
- const farmApp = _chunkP253SZJFcjs.createFarmApp.call(void 0, config, projectModuleServer);
15617
+ const farmApp = _chunkTI4BZV6Mcjs.createFarmApp.call(void 0, config, projectModuleServer);
15593
15618
  if (options.universal !== false) farmApp.getRouteManager().keepBuildSourceSnapshot();
15594
15619
  await farmApp.initialize();
15595
15620
  const routeManager = farmApp.getRouteManager();
@@ -15601,7 +15626,7 @@ async function buildWithProductionNodeEnv(inputConfig, options) {
15601
15626
  storage: config.storage,
15602
15627
  plugins: config.plugins,
15603
15628
  extraRoutes: [
15604
- ..._optionalChain([config, 'access', _354 => _354.openapi, 'optionalAccess', _355 => _355.enabled]) && config.openapi.route ? [config.openapi.route] : [],
15629
+ ..._optionalChain([config, 'access', _349 => _349.openapi, 'optionalAccess', _350 => _350.enabled]) && config.openapi.route ? [config.openapi.route] : [],
15605
15630
  ..._chunkHR5GU4UUcjs.getFarmDocsRouteTypeEntries.call(void 0, config.docs)
15606
15631
  ],
15607
15632
  suppressLintOnLink: config.suppressLintOnLink,
@@ -15612,7 +15637,7 @@ async function buildWithProductionNodeEnv(inputConfig, options) {
15612
15637
  const message = error instanceof Error ? error.message : String(error);
15613
15638
  _chunk7U4XF76Rcjs.logger.warn(`Route type generation failed (farm.d.ts may be stale): ${message}`);
15614
15639
  });
15615
- const apiRouteManager = new (0, _chunk5P65LXGUcjs.APIRouteManager)(
15640
+ const apiRouteManager = new (0, _chunkWSQ3S3NVcjs.APIRouteManager)(
15616
15641
  _chunk52Q4OB4Acjs.getFarmAppDirectories.call(void 0, config),
15617
15642
  projectModuleServer,
15618
15643
  {
@@ -15687,7 +15712,7 @@ async function buildWithProductionNodeEnv(inputConfig, options) {
15687
15712
  throw error;
15688
15713
  } finally {
15689
15714
  try {
15690
- await _optionalChain([projectModuleServer, 'optionalAccess', _356 => _356.close, 'call', _357 => _357()]);
15715
+ await _optionalChain([projectModuleServer, 'optionalAccess', _351 => _351.close, 'call', _352 => _352()]);
15691
15716
  } finally {
15692
15717
  rendererBuild.abort();
15693
15718
  }
@@ -15699,7 +15724,7 @@ async function createProjectModuleServer(createViteServer, config, root, buildLi
15699
15724
  ssr: true,
15700
15725
  buildLifetime
15701
15726
  });
15702
- const viteConfig = _chunkP253SZJFcjs.mergeFarmViteConfig.call(void 0,
15727
+ const viteConfig = _chunkTI4BZV6Mcjs.mergeFarmViteConfig.call(void 0,
15703
15728
  {
15704
15729
  root,
15705
15730
  appType: "custom",
@@ -15711,12 +15736,13 @@ async function createProjectModuleServer(createViteServer, config, root, buildLi
15711
15736
  },
15712
15737
  plugins: [
15713
15738
  ...rendererVitePlugins,
15714
- _chunkP253SZJFcjs.farmFontImportsPlugin.call(void 0, {
15739
+ _chunkTI4BZV6Mcjs.farmFontImportsPlugin.call(void 0, {
15715
15740
  root,
15716
15741
  basePath: config.basePath,
15717
- publicDir: config.publicDir
15742
+ publicDir: config.publicDir,
15743
+ isLayoutModule: (id) => _chunkTI4BZV6Mcjs.isFarmLayoutModule.call(void 0, id, _chunk52Q4OB4Acjs.getFarmAppDirectories.call(void 0, config))
15718
15744
  }),
15719
- _chunkQYDGIXQ5cjs.farmEnvironmentFunctionsPlugin.call(void 0, { renderer: config.renderer }),
15745
+ _chunkU3A46QFDcjs.farmEnvironmentFunctionsPlugin.call(void 0, { renderer: config.renderer }),
15720
15746
  // Route modules load here at build time (rendering config, prerendering): `server-only`
15721
15747
  // resolves as it does in the server build. Module-entry packages load pre-bundled, as in
15722
15748
  // `farm dev`: unbundled, lucide-react alone is ~1,750 modules through the module runner,
@@ -15732,7 +15758,7 @@ async function createProjectModuleServer(createViteServer, config, root, buildLi
15732
15758
  hmr: false
15733
15759
  },
15734
15760
  resolve: {
15735
- alias: _chunkP253SZJFcjs.createFarmSourceAlias.call(void 0, root, config.srcDir),
15761
+ alias: _chunkTI4BZV6Mcjs.createFarmSourceAlias.call(void 0, root, config.srcDir),
15736
15762
  dedupe: [...config.renderer.dedupe || []]
15737
15763
  },
15738
15764
  optimizeDeps: {
@@ -15771,10 +15797,10 @@ async function createProjectModuleServer(createViteServer, config, root, buildLi
15771
15797
  noDiscovery: true
15772
15798
  },
15773
15799
  // An app or plugin that brings its own SSR environment keeps it.
15774
- environments: _optionalChain([viteConfig, 'access', _358 => _358.environments, 'optionalAccess', _359 => _359.ssr, 'optionalAccess', _360 => _360.dev, 'optionalAccess', _361 => _361.createEnvironment]) ? viteConfig.environments : {
15800
+ environments: _optionalChain([viteConfig, 'access', _353 => _353.environments, 'optionalAccess', _354 => _354.ssr, 'optionalAccess', _355 => _355.dev, 'optionalAccess', _356 => _356.createEnvironment]) ? viteConfig.environments : {
15775
15801
  ...viteConfig.environments,
15776
15802
  ssr: {
15777
- ..._optionalChain([viteConfig, 'access', _362 => _362.environments, 'optionalAccess', _363 => _363.ssr]),
15803
+ ..._optionalChain([viteConfig, 'access', _357 => _357.environments, 'optionalAccess', _358 => _358.ssr]),
15778
15804
  ...await createFarmProjectModuleSsrEnvironment()
15779
15805
  }
15780
15806
  }
@@ -15788,7 +15814,7 @@ async function buildClient2(viteBuild, config, root, srcDir, outputDir) {
15788
15814
  farmPlugin,
15789
15815
  farmServerOnlyEntriesPlugin
15790
15816
  } = await import("./vite.cjs");
15791
- const { PluginManager: PluginManager2 } = await import("./plugin-3PT7I26P.cjs");
15817
+ const { PluginManager: PluginManager2 } = await import("./plugin-MWO3G2XM.cjs");
15792
15818
  const pluginManager = new PluginManager2({
15793
15819
  config,
15794
15820
  isDev: false,
@@ -15810,14 +15836,14 @@ async function buildClient2(viteBuild, config, root, srcDir, outputDir) {
15810
15836
  farmNavigationPlugin(config.renderer),
15811
15837
  farmIslandContainersPlugin(config),
15812
15838
  farmPlugin(config, pluginManager),
15813
- _chunkQYDGIXQ5cjs.farmEnvironmentFunctionsPlugin.call(void 0, config)
15839
+ _chunkU3A46QFDcjs.farmEnvironmentFunctionsPlugin.call(void 0, config)
15814
15840
  ],
15815
15841
  mode: "production"
15816
15842
  });
15817
15843
  }
15818
15844
  async function buildSSR(viteBuild, config, root, srcDir, outputDir) {
15819
15845
  const { farmI18nClientBridgePlugin, farmIslandContainersPlugin, farmPlugin } = await import("./vite.cjs");
15820
- const { PluginManager: PluginManager2 } = await import("./plugin-3PT7I26P.cjs");
15846
+ const { PluginManager: PluginManager2 } = await import("./plugin-MWO3G2XM.cjs");
15821
15847
  const pluginManager = new PluginManager2({
15822
15848
  config,
15823
15849
  isDev: false,
@@ -15838,13 +15864,13 @@ async function buildSSR(viteBuild, config, root, srcDir, outputDir) {
15838
15864
  define: {
15839
15865
  __FARM_API_BASE_URL__: JSON.stringify(config.api.baseURL),
15840
15866
  __FARM_ENV__: JSON.stringify(_chunk3EIPOTZVcjs.createBundledEnv.call(void 0, config.env)),
15841
- __FARM_PUBLIC_ENV__: JSON.stringify(_optionalChain([config, 'access', _364 => _364.env, 'optionalAccess', _365 => _365.public]) || {})
15867
+ __FARM_PUBLIC_ENV__: JSON.stringify(_optionalChain([config, 'access', _359 => _359.env, 'optionalAccess', _360 => _360.public]) || {})
15842
15868
  },
15843
15869
  plugins: [
15844
15870
  farmI18nClientBridgePlugin(),
15845
15871
  farmIslandContainersPlugin(config),
15846
15872
  farmPlugin(config, pluginManager),
15847
- _chunkQYDGIXQ5cjs.farmEnvironmentFunctionsPlugin.call(void 0, config)
15873
+ _chunkU3A46QFDcjs.farmEnvironmentFunctionsPlugin.call(void 0, config)
15848
15874
  ],
15849
15875
  mode: "production"
15850
15876
  });
@@ -15872,7 +15898,7 @@ async function buildNitro(config, routeManager, apiRouteManager, serverRenderer,
15872
15898
  if (pluginManager) {
15873
15899
  nitroConfig = await pluginManager.runHookSerial("beforeNitroBuild", nitroConfig);
15874
15900
  }
15875
- const outputDir = _chunkFDU4Q4QPcjs.resolveDeployOutputPath.call(void 0, root, config.deploy.outputDir);
15901
+ const outputDir = _chunkMZR22RACcjs.resolveDeployOutputPath.call(void 0, root, config.deploy.outputDir);
15876
15902
  const serverOutputDir = _path2.default.join(outputDir, "server");
15877
15903
  const publicOutputDir = _path2.default.join(outputDir, "public");
15878
15904
  const { mkdir, cp } = await import("fs/promises");
@@ -15943,7 +15969,7 @@ async function buildNitro(config, routeManager, apiRouteManager, serverRenderer,
15943
15969
  root,
15944
15970
  preset,
15945
15971
  distDir,
15946
- outputDir: _chunkFDU4Q4QPcjs.resolveDeployOutputPath.call(void 0, root, config.deploy.outputDir)
15972
+ outputDir: _chunkMZR22RACcjs.resolveDeployOutputPath.call(void 0, root, config.deploy.outputDir)
15947
15973
  });
15948
15974
  }
15949
15975
  }