@farm.js/core 0.1.42 → 0.1.43

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 (235) hide show
  1. package/dist/{agent-mcp-ssVy_tea.d.mts → agent-mcp-3KDz4hr9.d.mts} +1 -1
  2. package/dist/{agent-mcp-SSD6L3VZ.d.ts → agent-mcp-6yRebHk7.d.ts} +1 -1
  3. package/dist/agent-runtime.d.mts +1 -1
  4. package/dist/agent-runtime.d.ts +1 -1
  5. package/dist/api/route-manager.d.mts +3 -3
  6. package/dist/api/route-manager.d.ts +3 -3
  7. package/dist/api/runtime.d.mts +2 -2
  8. package/dist/api/runtime.d.ts +2 -2
  9. package/dist/api.cjs +2 -2
  10. package/dist/api.d.mts +8 -3
  11. package/dist/api.d.ts +8 -3
  12. package/dist/api.mjs +1 -1
  13. package/dist/{app-KjFzdCqy.d.ts → app-8Db1zR-2.d.ts} +8 -4
  14. package/dist/{app-1h3lVT4a.d.mts → app-DlTWv4cn.d.mts} +8 -4
  15. package/dist/{app-manifest-D3RkVNuS.d.mts → app-manifest-TRzS7ZZ9.d.mts} +1 -1
  16. package/dist/{app-manifest-DaW8-tvX.d.ts → app-manifest-cO2jkG1F.d.ts} +1 -1
  17. package/dist/app-markdown.d.mts +2 -2
  18. package/dist/app-markdown.d.ts +2 -2
  19. package/dist/{chunk-ECKF2BAM.cjs → chunk-2GVF3C2F.cjs} +255 -42
  20. package/dist/chunk-2NXO5SBY.mjs +57 -0
  21. package/dist/chunk-3BROEWFY.cjs +39 -0
  22. package/dist/{chunk-NU25TRIO.mjs → chunk-4MRQ5OKQ.mjs} +11 -7
  23. package/dist/{chunk-375K2ZVU.mjs → chunk-4OCEMK72.mjs} +259 -48
  24. package/dist/{chunk-6PKXK4TY.mjs → chunk-53ZV6K65.mjs} +1 -1
  25. package/dist/{chunk-LYIZHJTK.cjs → chunk-5LPHJZSI.cjs} +14 -14
  26. package/dist/chunk-5NIWBWDD.mjs +97 -0
  27. package/dist/{chunk-NRDBW4MP.mjs → chunk-7IQQIPRZ.mjs} +10 -0
  28. package/dist/{chunk-QTEJGB5A.mjs → chunk-7SCCY6SI.mjs} +79 -176
  29. package/dist/chunk-APDGOKKE.cjs +148 -0
  30. package/dist/chunk-AZBSVLRM.cjs +132 -0
  31. package/dist/{chunk-ZS6HDNOM.cjs → chunk-BKPXWRTT.cjs} +6 -6
  32. package/dist/chunk-CEDPEDNW.cjs +98 -0
  33. package/dist/chunk-D5RFPV2H.mjs +148 -0
  34. package/dist/{chunk-724JLMS4.mjs → chunk-F646BZ4Y.mjs} +4 -2
  35. package/dist/{chunk-C5KVWHIH.cjs → chunk-G2Z5DGMS.cjs} +5 -3
  36. package/dist/{chunk-7YHSD3Z6.cjs → chunk-GVNCWSQV.cjs} +83 -29
  37. package/dist/{chunk-24SP5TGU.mjs → chunk-H4LXPWI2.mjs} +2 -2
  38. package/dist/chunk-H7BLEEAE.cjs +57 -0
  39. package/dist/{chunk-QKZMB7LY.cjs → chunk-HUMEHX24.cjs} +2 -2
  40. package/dist/{chunk-BD3D7EZV.cjs → chunk-IXFOBGLQ.cjs} +9 -3
  41. package/dist/{chunk-JG3MEQUH.cjs → chunk-JDJAPCR2.cjs} +420 -209
  42. package/dist/{chunk-MHN4UR5U.cjs → chunk-KFZZFZ7J.cjs} +7 -7
  43. package/dist/chunk-LRJRXXQZ.cjs +109 -0
  44. package/dist/{chunk-BXJ5HJTJ.cjs → chunk-LVABUXLA.cjs} +15 -11
  45. package/dist/{chunk-HCSVR4YZ.mjs → chunk-M3BXTWJM.mjs} +18 -0
  46. package/dist/{chunk-2JZHQDUY.mjs → chunk-NXO75WY4.mjs} +1 -1
  47. package/dist/{chunk-TUL355PH.mjs → chunk-OYSGGV6O.mjs} +135 -160
  48. package/dist/{chunk-JR4QCLJY.cjs → chunk-PDU4P2IC.cjs} +19 -1
  49. package/dist/chunk-PJEHUSHA.mjs +229 -0
  50. package/dist/chunk-QGH2RQVF.mjs +132 -0
  51. package/dist/{chunk-YWMZUGIS.mjs → chunk-R3ZFQJEF.mjs} +247 -34
  52. package/dist/{chunk-ZATTDMBW.cjs → chunk-RACQTC7K.cjs} +270 -367
  53. package/dist/{chunk-WSOBCAYO.cjs → chunk-RQYTOFQM.cjs} +23 -23
  54. package/dist/chunk-S34OBRMZ.mjs +109 -0
  55. package/dist/{chunk-TS4JHGUJ.mjs → chunk-S3ZEMCE6.mjs} +9 -3
  56. package/dist/{chunk-WWFTAUFG.cjs → chunk-SBH2JLLF.cjs} +12 -2
  57. package/dist/{chunk-YSLWRWWP.cjs → chunk-SKK6UF5P.cjs} +200 -46
  58. package/dist/chunk-T7J7E63D.cjs +144 -0
  59. package/dist/{chunk-PIZXONIS.mjs → chunk-TESO7EFU.mjs} +55 -1
  60. package/dist/{chunk-TCJ4A4A2.cjs → chunk-VIVQERJ5.cjs} +318 -344
  61. package/dist/{chunk-JIYYX7WU.mjs → chunk-VLXNGUKO.mjs} +1 -1
  62. package/dist/{chunk-OFZUJMCU.mjs → chunk-WPJQN64R.mjs} +195 -41
  63. package/dist/chunk-XARSG2TG.mjs +144 -0
  64. package/dist/chunk-XUGFRFD2.mjs +39 -0
  65. package/dist/{chunk-AHFRQMRX.cjs → chunk-YBDSTNMH.cjs} +1 -1
  66. package/dist/{chunk-U2UC7UGP.mjs → chunk-YGZH4T2X.mjs} +1 -1
  67. package/dist/chunk-YKUEJ3MG.cjs +229 -0
  68. package/dist/{chunk-IVQY6UTY.mjs → chunk-ZYWJIPKQ.mjs} +1 -1
  69. package/dist/{client-plugins-C9Py_50W.d.mts → client-plugins-Cv0OJtnM.d.mts} +21 -2
  70. package/dist/{client-plugins-DIem0I0W.d.ts → client-plugins-kwQuZcWq.d.ts} +21 -2
  71. package/dist/client-plugins.d.mts +1 -1
  72. package/dist/client-plugins.d.ts +1 -1
  73. package/dist/client.cjs +4 -3
  74. package/dist/client.d.mts +5 -5
  75. package/dist/client.d.ts +5 -5
  76. package/dist/client.mjs +3 -2
  77. package/dist/config.d.mts +1 -1
  78. package/dist/config.d.ts +1 -1
  79. package/dist/{devtools-Q3LBNUJ7.mjs → devtools-M22FEFPK.mjs} +3 -3
  80. package/dist/{devtools-2RY3EKHL.cjs → devtools-MLB3JJMC.cjs} +4 -4
  81. package/dist/docs.cjs +5 -5
  82. package/dist/docs.d.mts +2 -2
  83. package/dist/docs.d.ts +2 -2
  84. package/dist/docs.mjs +4 -4
  85. package/dist/index-CQOp8EmB.d.mts +48 -0
  86. package/dist/index-DAl0QTZS.d.ts +48 -0
  87. package/dist/index.cjs +40 -23
  88. package/dist/index.d.mts +15 -15
  89. package/dist/index.d.ts +15 -15
  90. package/dist/index.mjs +45 -28
  91. package/dist/integrations.d.mts +1 -1
  92. package/dist/integrations.d.ts +1 -1
  93. package/dist/internal/app-markdown-runtime.d.mts +2 -2
  94. package/dist/internal/app-markdown-runtime.d.ts +2 -2
  95. package/dist/internal/build-runtime.cjs +28 -14
  96. package/dist/internal/build-runtime.d.mts +12 -16
  97. package/dist/internal/build-runtime.d.ts +12 -16
  98. package/dist/internal/build-runtime.mjs +27 -13
  99. package/dist/internal/cli-runtime.cjs +22 -10
  100. package/dist/internal/cli-runtime.mjs +22 -10
  101. package/dist/internal/client-error-overlay.cjs +4 -4
  102. package/dist/internal/client-error-overlay.mjs +1 -1
  103. package/dist/internal/client-runtime.cjs +5 -1
  104. package/dist/internal/client-runtime.d.mts +1 -0
  105. package/dist/internal/client-runtime.d.ts +1 -0
  106. package/dist/internal/client-runtime.mjs +4 -0
  107. package/dist/internal/compression-runtime.d.mts +1 -1
  108. package/dist/internal/compression-runtime.d.ts +1 -1
  109. package/dist/internal/config-runtime.cjs +4 -4
  110. package/dist/internal/config-runtime.d.mts +2 -2
  111. package/dist/internal/config-runtime.d.ts +2 -2
  112. package/dist/internal/config-runtime.mjs +3 -3
  113. package/dist/internal/form-actions-client.cjs +18 -0
  114. package/dist/internal/form-actions-client.d.mts +5 -0
  115. package/dist/internal/form-actions-client.d.ts +5 -0
  116. package/dist/internal/form-actions-client.mjs +18 -0
  117. package/dist/internal/form-actions.cjs +18 -0
  118. package/dist/internal/form-actions.d.mts +14 -0
  119. package/dist/internal/form-actions.d.ts +14 -0
  120. package/dist/internal/form-actions.mjs +18 -0
  121. package/dist/internal/island-codec.cjs +22 -0
  122. package/dist/internal/island-codec.d.mts +29 -0
  123. package/dist/internal/island-codec.d.ts +29 -0
  124. package/dist/internal/island-codec.mjs +22 -0
  125. package/dist/internal/island-value-store.cjs +13 -0
  126. package/dist/internal/island-value-store.d.mts +6 -0
  127. package/dist/internal/island-value-store.d.ts +6 -0
  128. package/dist/internal/island-value-store.mjs +13 -0
  129. package/dist/internal/islands-runtime.cjs +77 -0
  130. package/dist/internal/islands-runtime.d.mts +57 -0
  131. package/dist/internal/islands-runtime.d.ts +57 -0
  132. package/dist/internal/islands-runtime.mjs +77 -0
  133. package/dist/internal/islands-server.cjs +19 -0
  134. package/dist/internal/islands-server.d.mts +3 -0
  135. package/dist/internal/islands-server.d.ts +3 -0
  136. package/dist/internal/islands-server.mjs +19 -0
  137. package/dist/internal/islx-client.cjs +5 -0
  138. package/dist/internal/islx-client.d.mts +2 -0
  139. package/dist/internal/islx-client.d.ts +2 -0
  140. package/dist/internal/islx-client.mjs +3 -0
  141. package/dist/internal/islx-react.cjs +4 -0
  142. package/dist/internal/islx-react.d.mts +1 -0
  143. package/dist/internal/islx-react.d.ts +1 -0
  144. package/dist/internal/islx-react.mjs +2 -0
  145. package/dist/internal/islx-server.cjs +5 -0
  146. package/dist/internal/islx-server.d.mts +2 -0
  147. package/dist/internal/islx-server.d.ts +2 -0
  148. package/dist/internal/islx-server.mjs +3 -0
  149. package/dist/internal/isolated-boundary.cjs +4 -3
  150. package/dist/internal/isolated-boundary.d.mts +13 -1
  151. package/dist/internal/isolated-boundary.d.ts +13 -1
  152. package/dist/internal/isolated-boundary.mjs +3 -2
  153. package/dist/internal/product-telemetry-runtime.cjs +2 -2
  154. package/dist/internal/product-telemetry-runtime.mjs +1 -1
  155. package/dist/internal/production-runtime.cjs +23 -6
  156. package/dist/internal/production-runtime.d.mts +20 -10
  157. package/dist/internal/production-runtime.d.ts +20 -10
  158. package/dist/internal/production-runtime.mjs +23 -6
  159. package/dist/internal/server-tree.cjs +6 -3
  160. package/dist/internal/server-tree.d.mts +25 -2
  161. package/dist/internal/server-tree.d.ts +25 -2
  162. package/dist/internal/server-tree.mjs +7 -4
  163. package/dist/island-value-protocol-BRayRghM.d.mts +12 -0
  164. package/dist/island-value-protocol-BRayRghM.d.ts +12 -0
  165. package/dist/markdown.d.mts +1 -1
  166. package/dist/markdown.d.ts +1 -1
  167. package/dist/middleware.d.mts +3 -3
  168. package/dist/middleware.d.ts +3 -3
  169. package/dist/navigation.cjs +5 -4
  170. package/dist/navigation.d.mts +4 -4
  171. package/dist/navigation.d.ts +4 -4
  172. package/dist/navigation.mjs +4 -3
  173. package/dist/og.d.mts +5 -0
  174. package/dist/og.d.ts +5 -0
  175. package/dist/plugin.cjs +17 -11
  176. package/dist/plugin.d.mts +3 -3
  177. package/dist/plugin.d.ts +3 -3
  178. package/dist/plugin.mjs +16 -10
  179. package/dist/{production-runtime-bjjWq-DA.d.ts → production-runtime-5nArjFpn.d.ts} +1 -1
  180. package/dist/{production-runtime-CHFKIgpW.d.mts → production-runtime-BzsF2z5F.d.mts} +1 -1
  181. package/dist/query/client.cjs +6 -5
  182. package/dist/query/client.mjs +2 -1
  183. package/dist/{render-plan-DOHg6wdO.d.mts → render-plan-B9yQorV4.d.mts} +4 -2
  184. package/dist/{render-plan-B2UndB4x.d.ts → render-plan-fg6E_HvL.d.ts} +4 -2
  185. package/dist/renderer/react/server.cjs +7 -6
  186. package/dist/renderer/react/server.d.mts +3 -1
  187. package/dist/renderer/react/server.d.ts +3 -1
  188. package/dist/renderer/react/server.mjs +5 -4
  189. package/dist/renderer-client.cjs +5 -4
  190. package/dist/renderer-client.d.mts +3 -3
  191. package/dist/renderer-client.d.ts +3 -3
  192. package/dist/renderer-client.mjs +2 -1
  193. package/dist/renderer.d.mts +3 -1
  194. package/dist/renderer.d.ts +3 -1
  195. package/dist/{request-DQcGfdgQ.d.mts → request-C4j_g-BH.d.mts} +1 -1
  196. package/dist/{request-DVNXRQrI.d.ts → request-gz8vFK0n.d.ts} +1 -1
  197. package/dist/request.d.mts +2 -2
  198. package/dist/request.d.ts +2 -2
  199. package/dist/{route-rendering-B_6fj-GG.d.ts → route-rendering-DamyKVi3.d.ts} +1 -1
  200. package/dist/{route-rendering-CEX4mFn-.d.mts → route-rendering-iTTOwz1f.d.mts} +1 -1
  201. package/dist/{router-CKHPBKXX.d.mts → router-EoSzHlos.d.mts} +1 -1
  202. package/dist/{router-CHEMHm1P.d.ts → router-OVjDqVo8.d.ts} +1 -1
  203. package/dist/routes.d.mts +1 -1
  204. package/dist/routes.d.ts +1 -1
  205. package/dist/rsc-pipeline-LK4K5JFK.mjs +77 -0
  206. package/dist/rsc-pipeline-YCDRJME4.cjs +77 -0
  207. package/dist/{runtime-Br2ZDTAv.d.ts → runtime-CwiuozLd.d.ts} +1 -1
  208. package/dist/{runtime-jj8TKNsy.d.mts → runtime-DDH4tiuF.d.mts} +1 -1
  209. package/dist/{schema-dev-notice-5JPE67AI.cjs → schema-dev-notice-77ZL23PL.cjs} +4 -4
  210. package/dist/{schema-dev-notice-WLPZ6WKU.mjs → schema-dev-notice-BLXOS6U2.mjs} +2 -2
  211. package/dist/server-plugins.d.mts +2 -2
  212. package/dist/server-plugins.d.ts +2 -2
  213. package/dist/server.cjs +55 -37
  214. package/dist/server.d.mts +15 -10
  215. package/dist/server.d.ts +15 -10
  216. package/dist/server.mjs +35 -17
  217. package/dist/{spa-router-BEvS9Erj.d.mts → spa-router-Br4qFCWf.d.mts} +8 -3
  218. package/dist/{spa-router-DmCuH5B7.d.ts → spa-router-BsWUKH73.d.ts} +8 -3
  219. package/dist/{ssg-gT093ETk.d.ts → ssg-Csy2vwpi.d.ts} +2 -2
  220. package/dist/{ssg-57v6cZcW.d.mts → ssg-Donyfcxy.d.mts} +2 -2
  221. package/dist/testing.d.mts +1 -1
  222. package/dist/testing.d.ts +1 -1
  223. package/dist/{utils-CCTKvR-P.d.ts → utils-Luk72LXC.d.ts} +1 -1
  224. package/dist/{utils-raHHQVyL.d.mts → utils-d_k1ZZw0.d.mts} +1 -1
  225. package/dist/version.cjs +2 -2
  226. package/dist/version.mjs +1 -1
  227. package/dist/vite.cjs +17 -11
  228. package/dist/vite.d.mts +6 -4
  229. package/dist/vite.d.ts +6 -4
  230. package/dist/vite.mjs +16 -10
  231. package/package.json +53 -1
  232. package/dist/{chunk-35WS7P2V.mjs → chunk-26CXZR6L.mjs} +3 -3
  233. package/dist/{chunk-QEILRWVV.cjs → chunk-3XEMGDBF.cjs} +2 -2
  234. package/dist/{chunk-BPOTSHDO.cjs → chunk-IOAUK4OI.cjs} +2 -2
  235. package/dist/{chunk-BYR3RQPB.mjs → chunk-T76H22WI.mjs} +4 -4
@@ -2,7 +2,7 @@
2
2
 
3
3
 
4
4
 
5
- var _chunkQEILRWVVcjs = require('./chunk-QEILRWVV.cjs');
5
+ var _chunk3XEMGDBFcjs = require('./chunk-3XEMGDBF.cjs');
6
6
 
7
7
 
8
8
 
@@ -24,7 +24,8 @@ var _chunkQEILRWVVcjs = require('./chunk-QEILRWVV.cjs');
24
24
 
25
25
 
26
26
 
27
- var _chunk7YHSD3Z6cjs = require('./chunk-7YHSD3Z6.cjs');
27
+
28
+ var _chunkGVNCWSQVcjs = require('./chunk-GVNCWSQV.cjs');
28
29
 
29
30
 
30
31
 
@@ -35,9 +36,15 @@ var _chunk7YHSD3Z6cjs = require('./chunk-7YHSD3Z6.cjs');
35
36
  var _chunkBMOBTMDRcjs = require('./chunk-BMOBTMDR.cjs');
36
37
 
37
38
 
39
+ var _chunk3BROEWFYcjs = require('./chunk-3BROEWFY.cjs');
40
+
41
+
38
42
  var _chunkCBXBGM72cjs = require('./chunk-CBXBGM72.cjs');
39
43
 
40
44
 
45
+ var _chunkAPDGOKKEcjs = require('./chunk-APDGOKKE.cjs');
46
+
47
+
41
48
 
42
49
  var _chunkMWSK6C4Jcjs = require('./chunk-MWSK6C4J.cjs');
43
50
 
@@ -56,15 +63,16 @@ var _chunkCY2ZQ5C6cjs = require('./chunk-CY2ZQ5C6.cjs');
56
63
 
57
64
 
58
65
 
59
- var _chunkJR4QCLJYcjs = require('./chunk-JR4QCLJY.cjs');
60
-
61
66
 
62
- var _chunkQ5B3KJBPcjs = require('./chunk-Q5B3KJBP.cjs');
67
+ var _chunkPDU4P2ICcjs = require('./chunk-PDU4P2IC.cjs');
63
68
 
64
69
 
65
70
  var _chunkYJRZR7VUcjs = require('./chunk-YJRZR7VU.cjs');
66
71
 
67
72
 
73
+ var _chunkQ5B3KJBPcjs = require('./chunk-Q5B3KJBP.cjs');
74
+
75
+
68
76
 
69
77
 
70
78
 
@@ -171,7 +179,6 @@ var _chunkXJXBIP67cjs = require('./chunk-XJXBIP67.cjs');
171
179
 
172
180
 
173
181
 
174
-
175
182
  var _chunkLYLEZIG3cjs = require('./chunk-LYLEZIG3.cjs');
176
183
 
177
184
 
@@ -237,7 +244,7 @@ var _chunk5NAVKJCZcjs = require('./chunk-5NAVKJCZ.cjs');
237
244
  var _chunk4TLUFAIPcjs = require('./chunk-4TLUFAIP.cjs');
238
245
 
239
246
 
240
- var _chunkAHFRQMRXcjs = require('./chunk-AHFRQMRX.cjs');
247
+ var _chunkYBDSTNMHcjs = require('./chunk-YBDSTNMH.cjs');
241
248
 
242
249
 
243
250
 
@@ -732,7 +739,7 @@ function getClientModuleHydrationPlan(modulePath, root, mode = "off", options =
732
739
  ...costGuardExceeded ? { costGuardExceeded: true } : {},
733
740
  ...fallbackReason ? { fallbackReason } : {}
734
741
  }), "emptyPlan");
735
- const asyncOwner = metadata.suppressedAsyncHydration === true && options.asyncOwnerIslands === true;
742
+ const asyncOwner = (metadata.suppressedAsyncHydration === true || options.serverOwners === true) && options.asyncOwnerIslands === true;
736
743
  if (mode === "off" && !asyncOwner) return emptyPlan();
737
744
  const resolvedPath = resolveOwnerSourcePath(resolveModuleSourcePath(modulePath, root), root);
738
745
  const content = readIfExists(_nullishCoalesce(resolvedPath, () => ( "")));
@@ -1485,7 +1492,7 @@ function getProjectImportAliases(projectRoot) {
1485
1492
  return "-";
1486
1493
  }
1487
1494
  }).join(":");
1488
- const sourceDir = _chunkJR4QCLJYcjs.getFarmProjectSourceDir.call(void 0, projectRoot);
1495
+ const sourceDir = _chunkPDU4P2ICcjs.getFarmProjectSourceDir.call(void 0, projectRoot);
1489
1496
  const cacheStamp = `${stamp}:${sourceDir}`;
1490
1497
  const cached = projectImportAliasCache.get(projectRoot);
1491
1498
  if (_optionalChain([cached, 'optionalAccess', _89 => _89.stamp]) === cacheStamp) return cached.aliases;
@@ -1746,56 +1753,6 @@ function resolveSourceCandidate(candidates) {
1746
1753
  }
1747
1754
  _chunkS3JO3N4Hcjs.__name.call(void 0, resolveSourceCandidate, "resolveSourceCandidate");
1748
1755
 
1749
- // src/navigation/render-plan.ts
1750
- function createFarmRouteRenderPlan(input = {}) {
1751
- const pageShouldHydrate = input.pageShouldHydrate === true;
1752
- const layoutShouldHydrate = input.layoutShouldHydrate === true;
1753
- const hydration = pageShouldHydrate ? layoutShouldHydrate ? "route-and-layout-islands" : "route-island" : layoutShouldHydrate ? "layout-island" : "none";
1754
- const rendering = input.rendering;
1755
- const cache2 = _optionalChain([rendering, 'optionalAccess', _104 => _104.ssg]) ? typeof rendering.revalidate === "number" && rendering.revalidate > 0 ? { mode: "revalidate", revalidate: rendering.revalidate } : { mode: "static" } : { mode: "dynamic" };
1756
- return {
1757
- version: 1,
1758
- output: "html",
1759
- navigation: "html-fragment",
1760
- hydration,
1761
- islandStrategy: hydration === "none" ? null : _nullishCoalesce(input.islandStrategy, () => ( "load")),
1762
- cache: cache2
1763
- };
1764
- }
1765
- _chunkS3JO3N4Hcjs.__name.call(void 0, createFarmRouteRenderPlan, "createFarmRouteRenderPlan");
1766
- function getFarmFragmentCacheControl(plan) {
1767
- if (plan.cache.mode === "static") {
1768
- return "public, max-age=0, s-maxage=31536000, immutable";
1769
- }
1770
- if (plan.cache.mode === "revalidate") {
1771
- const seconds = Math.max(1, _nullishCoalesce(plan.cache.revalidate, () => ( 1)));
1772
- return `public, max-age=0, s-maxage=${seconds}, stale-while-revalidate=${seconds}`;
1773
- }
1774
- return "private, max-age=0";
1775
- }
1776
- _chunkS3JO3N4Hcjs.__name.call(void 0, getFarmFragmentCacheControl, "getFarmFragmentCacheControl");
1777
- function parseFarmLayoutChainHeader(value) {
1778
- if (!value || value.length > 8192) return [];
1779
- try {
1780
- const parsed = JSON.parse(value);
1781
- if (!Array.isArray(parsed) || parsed.length > 64) return [];
1782
- return parsed.filter(
1783
- (pattern) => typeof pattern === "string" && pattern.startsWith("/") && pattern.length <= 512
1784
- );
1785
- } catch (e8) {
1786
- return [];
1787
- }
1788
- }
1789
- _chunkS3JO3N4Hcjs.__name.call(void 0, parseFarmLayoutChainHeader, "parseFarmLayoutChainHeader");
1790
- function getSharedLayoutPrefixLength(current, next) {
1791
- let index = 0;
1792
- while (index < current.length && index < next.length && current[index] === next[index]) {
1793
- index++;
1794
- }
1795
- return index;
1796
- }
1797
- _chunkS3JO3N4Hcjs.__name.call(void 0, getSharedLayoutPrefixLength, "getSharedLayoutPrefixLength");
1798
-
1799
1756
  // src/routing/route-manager.ts
1800
1757
 
1801
1758
 
@@ -1956,8 +1913,8 @@ var _RouteManager = class _RouteManager {
1956
1913
  )
1957
1914
  );
1958
1915
  this.orderedLayouts = Array.from(this.layouts.values()).sort(
1959
- (left, right) => _chunk7YHSD3Z6cjs.getRouteDirectoryDepth.call(void 0, left.pattern) - _chunk7YHSD3Z6cjs.getRouteDirectoryDepth.call(void 0, right.pattern)
1960
- ).map((entry) => ({ entry, groupScope: _chunk7YHSD3Z6cjs.getRouteGroupScope.call(void 0, entry.pattern) }));
1916
+ (left, right) => _chunkGVNCWSQVcjs.getRouteDirectoryDepth.call(void 0, left.pattern) - _chunkGVNCWSQVcjs.getRouteDirectoryDepth.call(void 0, right.pattern)
1917
+ ).map((entry) => ({ entry, groupScope: _chunkGVNCWSQVcjs.getRouteGroupScope.call(void 0, entry.pattern) }));
1961
1918
  for (const slot of this.routeSlots.values()) {
1962
1919
  if (!this.routeSlotOwnerSegments.has(slot.ownerPattern)) {
1963
1920
  this.routeSlotOwnerSegments.set(
@@ -2068,7 +2025,7 @@ var _RouteManager = class _RouteManager {
2068
2025
  matchRedirect(pathname, search = "") {
2069
2026
  const i18n = this.getI18nConfig();
2070
2027
  const localeMatch = i18n ? _chunkBIDYX3SLcjs.resolveFarmLocalePath.call(void 0, pathname, i18n) : void 0;
2071
- const routePathname = _optionalChain([localeMatch, 'optionalAccess', _105 => _105.pathname]) || pathname;
2028
+ const routePathname = _optionalChain([localeMatch, 'optionalAccess', _104 => _104.pathname]) || pathname;
2072
2029
  const normalizedPath = routePathname === "/" ? "/" : routePathname.replace(/\/$/, "");
2073
2030
  for (const redirectEntry of this.redirects.values()) {
2074
2031
  const match = _chunk5QIKR7RRcjs.matchRoute.call(void 0, normalizedPath, redirectEntry.route.segments);
@@ -2079,7 +2036,7 @@ var _RouteManager = class _RouteManager {
2079
2036
  destination: _chunkYX3DBN4Mcjs.appendFarmRedirectQuery.call(void 0,
2080
2037
  this.localizeRedirectDestination(
2081
2038
  interpolateRedirectDestination(redirectEntry.definition.destination, match.params),
2082
- _optionalChain([localeMatch, 'optionalAccess', _106 => _106.locale])
2039
+ _optionalChain([localeMatch, 'optionalAccess', _105 => _105.locale])
2083
2040
  ),
2084
2041
  search
2085
2042
  ),
@@ -2187,7 +2144,7 @@ var _RouteManager = class _RouteManager {
2187
2144
  */
2188
2145
  generateClientManifest(projectRoot = this.config.root) {
2189
2146
  const normalizedProjectRoot = path4.default.resolve(projectRoot);
2190
- if (_optionalChain([this, 'access', _107 => _107.clientManifestCache, 'optionalAccess', _108 => _108.projectRoot]) === normalizedProjectRoot) {
2147
+ if (_optionalChain([this, 'access', _106 => _106.clientManifestCache, 'optionalAccess', _107 => _107.projectRoot]) === normalizedProjectRoot) {
2191
2148
  return this.clientManifestCache.manifest;
2192
2149
  }
2193
2150
  const toUrlPath = /* @__PURE__ */ _chunkS3JO3N4Hcjs.__name.call(void 0, (absolutePath) => {
@@ -2205,15 +2162,15 @@ var _RouteManager = class _RouteManager {
2205
2162
  const unsupportedIntegrationProvider = integrationProviders.find(
2206
2163
  (provider) => provider.supportsIsolatedHydration !== true
2207
2164
  );
2208
- if (_optionalChain([this, 'access', _109 => _109.config, 'access', _110 => _110.experimental, 'optionalAccess', _111 => _111.isolatedClientHydration]) === "enabled" && _optionalChain([this, 'access', _112 => _112.config, 'access', _113 => _113.experimental, 'optionalAccess', _114 => _114.serverComponents]) !== true && unsupportedIntegrationProvider) {
2165
+ if (_optionalChain([this, 'access', _108 => _108.config, 'access', _109 => _109.experimental, 'optionalAccess', _110 => _110.isolatedClientHydration]) === "enabled" && _chunkPDU4P2ICcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([this, 'access', _111 => _111.config, 'access', _112 => _112.experimental, 'optionalAccess', _113 => _113.serverComponents])) !== "rsc" && unsupportedIntegrationProvider) {
2209
2166
  _chunk5QIKR7RRcjs.logger.warn(
2210
2167
  `[Farm.js] isolated hydration kept route-wide because integration provider "${unsupportedIntegrationProvider.name}" does not declare supportsIsolatedHydration: true.`
2211
2168
  );
2212
2169
  }
2213
2170
  const isolatedMode = resolveFarmIsolatedClientHydrationMode(
2214
- _optionalChain([this, 'access', _115 => _115.config, 'access', _116 => _116.experimental, 'optionalAccess', _117 => _117.isolatedClientHydration]),
2171
+ _optionalChain([this, 'access', _114 => _114.config, 'access', _115 => _115.experimental, 'optionalAccess', _116 => _116.isolatedClientHydration]),
2215
2172
  {
2216
- serverComponents: _optionalChain([this, 'access', _118 => _118.config, 'access', _119 => _119.experimental, 'optionalAccess', _120 => _120.serverComponents]) === true,
2173
+ serverComponents: _chunkPDU4P2ICcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([this, 'access', _117 => _117.config, 'access', _118 => _118.experimental, 'optionalAccess', _119 => _119.serverComponents])) === "rsc",
2217
2174
  hasUnsupportedIntegrationProvider: Boolean(unsupportedIntegrationProvider)
2218
2175
  }
2219
2176
  );
@@ -2238,12 +2195,10 @@ var _RouteManager = class _RouteManager {
2238
2195
  );
2239
2196
  const routeEntries = Array.from(this.routes.values()).map((entry) => ({
2240
2197
  entry,
2241
- metadata: _chunkSZLNU3GJcjs.isFarmMarkdownPageFile.call(void 0, entry.modulePath) ? markdownPagePlan() : getClientModuleHydrationPlan(
2242
- entry.modulePath,
2243
- normalizedProjectRoot,
2244
- isolatedMode,
2245
- planOptions
2246
- )
2198
+ metadata: _chunkSZLNU3GJcjs.isFarmMarkdownPageFile.call(void 0, entry.modulePath) ? markdownPagePlan() : getClientModuleHydrationPlan(entry.modulePath, normalizedProjectRoot, isolatedMode, {
2199
+ ...planOptions,
2200
+ serverOwners: _chunkPDU4P2ICcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([this, 'access', _120 => _120.config, 'access', _121 => _121.experimental, 'optionalAccess', _122 => _122.serverComponents])) === "islands"
2201
+ })
2247
2202
  }));
2248
2203
  const markdownFallback = routeEntries.find(
2249
2204
  ({ entry, metadata }) => _chunkSZLNU3GJcjs.isFarmMarkdownPageFile.call(void 0, entry.modulePath) && metadata.fallbackReason
@@ -2253,9 +2208,9 @@ var _RouteManager = class _RouteManager {
2253
2208
  `[Farm.js] client components in Markdown pages stay static: ${markdownFallback.metadata.fallbackReason}.`
2254
2209
  );
2255
2210
  }
2256
- const markdownStaticPackages = _optionalChain([routeEntries, 'access', _121 => _121.find, 'call', _122 => _122(
2211
+ const markdownStaticPackages = _optionalChain([routeEntries, 'access', _123 => _123.find, 'call', _124 => _124(
2257
2212
  ({ entry, metadata }) => _chunkSZLNU3GJcjs.isFarmMarkdownPageFile.call(void 0, entry.modulePath) && metadata.staticPackageBoundaries
2258
- ), 'optionalAccess', _123 => _123.metadata, 'access', _124 => _124.staticPackageBoundaries]);
2213
+ ), 'optionalAccess', _125 => _125.metadata, 'access', _126 => _126.staticPackageBoundaries]);
2259
2214
  if (markdownStaticPackages) {
2260
2215
  _chunk5QIKR7RRcjs.logger.info(
2261
2216
  `[Farm.js] Markdown pages render client components from ${markdownStaticPackages.join(", ")} as static HTML: package client components cannot be isolated yet.`
@@ -2270,15 +2225,15 @@ var _RouteManager = class _RouteManager {
2270
2225
  enforceFarmIsolatedHydrationRouteBudget(
2271
2226
  layoutEntries.map(({ entry, metadata }) => ({
2272
2227
  pattern: entry.pattern,
2273
- depth: _chunk7YHSD3Z6cjs.getRouteDirectoryDepth.call(void 0, entry.pattern),
2228
+ depth: _chunkGVNCWSQVcjs.getRouteDirectoryDepth.call(void 0, entry.pattern),
2274
2229
  metadata
2275
2230
  })),
2276
2231
  routeEntries.map(({ entry, metadata }) => ({
2277
2232
  pattern: getRouteEntryDirectory(entry),
2278
- depth: _chunk7YHSD3Z6cjs.getRouteDirectoryDepth.call(void 0, getRouteEntryDirectory(entry)),
2233
+ depth: _chunkGVNCWSQVcjs.getRouteDirectoryDepth.call(void 0, getRouteEntryDirectory(entry)),
2279
2234
  metadata
2280
2235
  })),
2281
- _chunk7YHSD3Z6cjs.routeBoundaryCoversDirectory
2236
+ _chunkGVNCWSQVcjs.routeBoundaryCoversDirectory
2282
2237
  );
2283
2238
  for (const { entry, metadata } of [...layoutEntries, ...routeEntries]) {
2284
2239
  if (!metadata.costGuardExceeded) continue;
@@ -2297,7 +2252,7 @@ var _RouteManager = class _RouteManager {
2297
2252
  const routes = routeEntries.map(({ entry, metadata }) => {
2298
2253
  const programmaticPage = this.programmaticPages.get(entry.modulePath);
2299
2254
  const layoutShouldHydrate = layoutEntries.some(
2300
- ({ entry: layout, metadata: layoutMetadata }) => layoutMetadata.shouldHydrate && _chunk7YHSD3Z6cjs.routeBoundaryCoversDirectory.call(void 0, layout.pattern, getRouteEntryDirectory(entry))
2255
+ ({ entry: layout, metadata: layoutMetadata }) => layoutMetadata.shouldHydrate && _chunkGVNCWSQVcjs.routeBoundaryCoversDirectory.call(void 0, layout.pattern, getRouteEntryDirectory(entry))
2301
2256
  );
2302
2257
  return {
2303
2258
  pattern: entry.pattern,
@@ -2314,14 +2269,14 @@ var _RouteManager = class _RouteManager {
2314
2269
  }))
2315
2270
  } : {},
2316
2271
  ...usesFarmServerTree(metadata) ? { serverTree: true } : {},
2317
- renderPlan: createFarmRouteRenderPlan({
2272
+ renderPlan: _chunkGVNCWSQVcjs.createFarmRouteRenderPlan.call(void 0, {
2318
2273
  pageShouldHydrate: metadata.shouldHydrate,
2319
2274
  layoutShouldHydrate,
2320
2275
  islandStrategy: metadata.islandStrategy
2321
2276
  }),
2322
2277
  suppressedAsyncHydration: metadata.suppressedAsyncHydration,
2323
2278
  ...metadata.suppressedAsyncHydration && metadata.fallbackReason ? { suppressedAsyncHydrationReason: metadata.fallbackReason } : {},
2324
- search: _chunkCGVPXIRNcjs.getProgrammaticRouteSearchClientOptions.call(void 0, _optionalChain([programmaticPage, 'optionalAccess', _125 => _125.search])),
2279
+ search: _chunkCGVPXIRNcjs.getProgrammaticRouteSearchClientOptions.call(void 0, _optionalChain([programmaticPage, 'optionalAccess', _127 => _127.search])),
2325
2280
  segments: entry.route.segments.map((seg) => ({
2326
2281
  segment: seg.segment,
2327
2282
  isDynamic: seg.isDynamic,
@@ -2404,7 +2359,7 @@ var _RouteManager = class _RouteManager {
2404
2359
  getIsolatedClientBoundaryModules(projectRoot = this.config.root) {
2405
2360
  const normalizedProjectRoot = path4.default.resolve(projectRoot);
2406
2361
  this.generateClientManifest(normalizedProjectRoot);
2407
- return _nullishCoalesce(_optionalChain([this, 'access', _126 => _126.clientManifestCache, 'optionalAccess', _127 => _127.isolatedClientBoundaryModules]), () => ( /* @__PURE__ */ new Set()));
2362
+ return _nullishCoalesce(_optionalChain([this, 'access', _128 => _128.clientManifestCache, 'optionalAccess', _129 => _129.isolatedClientBoundaryModules]), () => ( /* @__PURE__ */ new Set()));
2408
2363
  }
2409
2364
  /**
2410
2365
  * Invalidate build-time route metadata after a page or layout changes in dev.
@@ -2479,7 +2434,7 @@ var _RouteManager = class _RouteManager {
2479
2434
  */
2480
2435
  createRoutePattern(route) {
2481
2436
  if (route.segments.length === 0) return "/";
2482
- return "/" + route.segments.map(_chunk7YHSD3Z6cjs.formatRouteSegment).join("/");
2437
+ return "/" + route.segments.map(_chunkGVNCWSQVcjs.formatRouteSegment).join("/");
2483
2438
  }
2484
2439
  registerPageRoute(entry) {
2485
2440
  _chunkNO3WWW3Ncjs.assertUniqueRouteParameters.call(void 0, entry.pattern);
@@ -2548,7 +2503,7 @@ var _RouteManager = class _RouteManager {
2548
2503
  if (!primaryFile) continue;
2549
2504
  const modulePath = path4.default.join(appDir, primaryFile);
2550
2505
  const existing = this.routes.get(pattern);
2551
- if (_optionalChain([existing, 'optionalAccess', _128 => _128.sourceRoot]) === source.root) {
2506
+ if (_optionalChain([existing, 'optionalAccess', _130 => _130.sourceRoot]) === source.root) {
2552
2507
  throw new Error(
2553
2508
  `Duplicate page route "${pattern}". Found both ${existing.modulePath} and ${modulePath}.`
2554
2509
  );
@@ -2573,9 +2528,9 @@ var _RouteManager = class _RouteManager {
2573
2528
  for (const file of files) {
2574
2529
  const route = _chunk5QIKR7RRcjs.parseRoutePath.call(void 0, file);
2575
2530
  const modulePath = path4.default.join(appDir, file);
2576
- const pattern = _chunk7YHSD3Z6cjs.createRouteDirectoryPattern.call(void 0, route);
2531
+ const pattern = _chunkGVNCWSQVcjs.createRouteDirectoryPattern.call(void 0, route);
2577
2532
  const existing = target.get(pattern);
2578
- if (_optionalChain([existing, 'optionalAccess', _129 => _129.sourceRoot]) === source.root) {
2533
+ if (_optionalChain([existing, 'optionalAccess', _131 => _131.sourceRoot]) === source.root) {
2579
2534
  throw new Error(
2580
2535
  `Duplicate ${kind} route "${pattern}". Found both ${existing.modulePath} and ${modulePath}.`
2581
2536
  );
@@ -2595,10 +2550,10 @@ var _RouteManager = class _RouteManager {
2595
2550
  const modulePath = path4.default.join(appDir, file);
2596
2551
  const pattern = this.createRoutePattern(slot.route);
2597
2552
  const ownerPattern = this.createRoutePattern(slot.ownerRoute);
2598
- const ownerDirectory = _chunk7YHSD3Z6cjs.createRouteDirectoryPattern.call(void 0, slot.ownerRoute);
2553
+ const ownerDirectory = _chunkGVNCWSQVcjs.createRouteDirectoryPattern.call(void 0, slot.ownerRoute);
2599
2554
  const key = `${ownerPattern}:${slot.name}:${slot.interception ? "intercept" : "slot"}:${slot.fallback ? "default" : pattern}`;
2600
2555
  const existing = this.routeSlots.get(key);
2601
- if (_optionalChain([existing, 'optionalAccess', _130 => _130.sourceRoot]) === source.root) {
2556
+ if (_optionalChain([existing, 'optionalAccess', _132 => _132.sourceRoot]) === source.root) {
2602
2557
  throw new Error(
2603
2558
  `Duplicate route slot "${slot.name}" for "${pattern}". Found both ${existing.modulePath} and ${modulePath}.`
2604
2559
  );
@@ -2627,7 +2582,7 @@ var _RouteManager = class _RouteManager {
2627
2582
  const key = `${kind}:${pattern}`;
2628
2583
  const existing = this.metadataImages.get(key);
2629
2584
  const sourceType = isStaticMetadataImageFile(file) ? "static" : "module";
2630
- if (_optionalChain([existing, 'optionalAccess', _131 => _131.sourceRoot]) === source.root) {
2585
+ if (_optionalChain([existing, 'optionalAccess', _133 => _133.sourceRoot]) === source.root) {
2631
2586
  throw new Error(
2632
2587
  `Duplicate ${fileName} route "${pattern}". Found both ${existing.modulePath} and ${modulePath}. Keep only one static image or module per route segment.`
2633
2588
  );
@@ -2655,7 +2610,7 @@ var _RouteManager = class _RouteManager {
2655
2610
  const pattern = this.createRoutePattern(route);
2656
2611
  const key = `${descriptor.kind}:${pattern}`;
2657
2612
  const existing = this.metadataRoutes.get(key);
2658
- if (_optionalChain([existing, 'optionalAccess', _132 => _132.sourceRoot]) === source.root) {
2613
+ if (_optionalChain([existing, 'optionalAccess', _134 => _134.sourceRoot]) === source.root) {
2659
2614
  throw new Error(
2660
2615
  `Duplicate ${descriptor.fileName} route "${pattern}". Found both ${existing.modulePath} and ${modulePath}. Keep only one .ts or .js metadata route per segment.`
2661
2616
  );
@@ -2694,7 +2649,7 @@ var _RouteManager = class _RouteManager {
2694
2649
  const route = _chunkCGVPXIRNcjs.parseProgrammaticRoutePath.call(void 0, definition.path, "page");
2695
2650
  const pattern = this.createRoutePattern(route);
2696
2651
  const existing = this.routes.get(pattern);
2697
- if (_optionalChain([existing, 'optionalAccess', _133 => _133.sourceRoot]) === source.root) {
2652
+ if (_optionalChain([existing, 'optionalAccess', _135 => _135.sourceRoot]) === source.root) {
2698
2653
  throw new Error(
2699
2654
  `Duplicate page route "${pattern}". Found both ${existing.modulePath} and programmatic route in ${filePath}.`
2700
2655
  );
@@ -2712,9 +2667,9 @@ var _RouteManager = class _RouteManager {
2712
2667
  }
2713
2668
  if (definition.kind === "layout") {
2714
2669
  const route = _chunkCGVPXIRNcjs.parseProgrammaticRoutePath.call(void 0, definition.path, "layout");
2715
- const pattern = _chunk7YHSD3Z6cjs.createRouteDirectoryPattern.call(void 0, route);
2670
+ const pattern = _chunkGVNCWSQVcjs.createRouteDirectoryPattern.call(void 0, route);
2716
2671
  const existing = this.layouts.get(pattern);
2717
- if (_optionalChain([existing, 'optionalAccess', _134 => _134.sourceRoot]) === source.root) {
2672
+ if (_optionalChain([existing, 'optionalAccess', _136 => _136.sourceRoot]) === source.root) {
2718
2673
  throw new Error(
2719
2674
  `Duplicate layout route "${pattern}". Found both ${existing.modulePath} and programmatic route in ${filePath}.`
2720
2675
  );
@@ -2743,7 +2698,7 @@ var _RouteManager = class _RouteManager {
2743
2698
  }
2744
2699
  async loadProgrammaticRoutesModule(filePath) {
2745
2700
  if (this.viteServer) {
2746
- const viteRoot = _optionalChain([this, 'access', _135 => _135.viteServer, 'access', _136 => _136.config, 'optionalAccess', _137 => _137.root]) || this.config.root || process.cwd();
2701
+ const viteRoot = _optionalChain([this, 'access', _137 => _137.viteServer, 'access', _138 => _138.config, 'optionalAccess', _139 => _139.root]) || this.config.root || process.cwd();
2747
2702
  return await _chunkPJ42JESYcjs.loadFarmDevModule.call(void 0, this.viteServer, _chunk5QIKR7RRcjs.toViteModuleId.call(void 0, filePath, viteRoot));
2748
2703
  }
2749
2704
  return await import(
@@ -2759,7 +2714,7 @@ var _RouteManager = class _RouteManager {
2759
2714
  const matchingLayouts = [];
2760
2715
  for (const { entry, groupScope } of this.orderedLayouts) {
2761
2716
  if (!_chunk5QIKR7RRcjs.matchRoutePrefixParts.call(void 0, pathnameParts, entry.route.segments)) continue;
2762
- if (groupScope !== null && !_chunk7YHSD3Z6cjs.isInRouteGroupScope.call(void 0, route && getRouteEntryDirectory(route), groupScope)) {
2717
+ if (groupScope !== null && !_chunkGVNCWSQVcjs.isInRouteGroupScope.call(void 0, route && getRouteEntryDirectory(route), groupScope)) {
2763
2718
  continue;
2764
2719
  }
2765
2720
  matchingLayouts.push(entry);
@@ -2840,14 +2795,14 @@ var _RouteManager = class _RouteManager {
2840
2795
  let page = route;
2841
2796
  for (const boundaryEntry of boundaries.values()) {
2842
2797
  if (!_chunk5QIKR7RRcjs.matchRoutePrefix.call(void 0, normalizedPath, boundaryEntry.route.segments)) continue;
2843
- const groupScope = _chunk7YHSD3Z6cjs.getRouteGroupScope.call(void 0, boundaryEntry.pattern);
2798
+ const groupScope = _chunkGVNCWSQVcjs.getRouteGroupScope.call(void 0, boundaryEntry.pattern);
2844
2799
  if (groupScope !== null) {
2845
2800
  if (page === void 0) page = this.matchPageRoute(_chunk5QIKR7RRcjs.splitRoutePath.call(void 0, normalizedPath));
2846
- if (!_chunk7YHSD3Z6cjs.isInRouteGroupScope.call(void 0, page && getRouteEntryDirectory(page), groupScope)) continue;
2801
+ if (!_chunkGVNCWSQVcjs.isInRouteGroupScope.call(void 0, page && getRouteEntryDirectory(page), groupScope)) continue;
2847
2802
  }
2848
2803
  const depth = boundaryEntry.route.segments.length;
2849
- const bestDepth = _nullishCoalesce(_optionalChain([bestMatch, 'optionalAccess', _138 => _138.route, 'access', _139 => _139.segments, 'access', _140 => _140.length]), () => ( -1));
2850
- if (!bestMatch || depth > bestDepth || depth === bestDepth && _chunk7YHSD3Z6cjs.getRouteDirectoryDepth.call(void 0, boundaryEntry.pattern) > _chunk7YHSD3Z6cjs.getRouteDirectoryDepth.call(void 0, bestMatch.pattern)) {
2804
+ const bestDepth = _nullishCoalesce(_optionalChain([bestMatch, 'optionalAccess', _140 => _140.route, 'access', _141 => _141.segments, 'access', _142 => _142.length]), () => ( -1));
2805
+ if (!bestMatch || depth > bestDepth || depth === bestDepth && _chunkGVNCWSQVcjs.getRouteDirectoryDepth.call(void 0, boundaryEntry.pattern) > _chunkGVNCWSQVcjs.getRouteDirectoryDepth.call(void 0, bestMatch.pattern)) {
2851
2806
  bestMatch = boundaryEntry;
2852
2807
  }
2853
2808
  }
@@ -2884,7 +2839,7 @@ var _RouteManager = class _RouteManager {
2884
2839
  pattern: entry.pattern
2885
2840
  }));
2886
2841
  const i18n = this.getI18nConfig();
2887
- const result = await _chunkQEILRWVVcjs.collectSSGPages.call(void 0, routes, (filePath) => this.loadRouteModule(filePath), {
2842
+ const result = await _chunk3XEMGDBFcjs.collectSSGPages.call(void 0, routes, (filePath) => this.loadRouteModule(filePath), {
2888
2843
  suggestStaticRendering: shouldSuggestStaticRenderingForI18n(i18n)
2889
2844
  });
2890
2845
  if (!i18n) {
@@ -2929,9 +2884,9 @@ var _RouteManager = class _RouteManager {
2929
2884
  async isRouteSSG(modulePath) {
2930
2885
  try {
2931
2886
  const mod = await this.loadRouteModule(modulePath);
2932
- const rendering = await _chunkQEILRWVVcjs.resolveRouteRenderingConfigFromFile.call(void 0, mod, modulePath);
2887
+ const rendering = await _chunk3XEMGDBFcjs.resolveRouteRenderingConfigFromFile.call(void 0, mod, modulePath);
2933
2888
  return rendering.ssg;
2934
- } catch (e9) {
2889
+ } catch (e8) {
2935
2890
  return false;
2936
2891
  }
2937
2892
  }
@@ -2941,9 +2896,9 @@ var _RouteManager = class _RouteManager {
2941
2896
  async hasRouteISR(modulePath) {
2942
2897
  try {
2943
2898
  const mod = await this.loadRouteModule(modulePath);
2944
- const rendering = await _chunkQEILRWVVcjs.resolveRouteRenderingConfigFromFile.call(void 0, mod, modulePath);
2899
+ const rendering = await _chunk3XEMGDBFcjs.resolveRouteRenderingConfigFromFile.call(void 0, mod, modulePath);
2945
2900
  return rendering.ssg && typeof rendering.revalidate === "number" && rendering.revalidate > 0;
2946
- } catch (e10) {
2901
+ } catch (e9) {
2947
2902
  return false;
2948
2903
  }
2949
2904
  }
@@ -2953,9 +2908,9 @@ var _RouteManager = class _RouteManager {
2953
2908
  async getRouteRevalidateInterval(modulePath) {
2954
2909
  try {
2955
2910
  const mod = await this.loadRouteModule(modulePath);
2956
- const rendering = await _chunkQEILRWVVcjs.resolveRouteRenderingConfigFromFile.call(void 0, mod, modulePath);
2911
+ const rendering = await _chunk3XEMGDBFcjs.resolveRouteRenderingConfigFromFile.call(void 0, mod, modulePath);
2957
2912
  return rendering.revalidate;
2958
- } catch (e11) {
2913
+ } catch (e10) {
2959
2914
  return void 0;
2960
2915
  }
2961
2916
  }
@@ -2963,7 +2918,7 @@ var _RouteManager = class _RouteManager {
2963
2918
  _chunkS3JO3N4Hcjs.__name.call(void 0, _RouteManager, "RouteManager");
2964
2919
  var RouteManager = _RouteManager;
2965
2920
  function getPageDirectoryField(route, pattern) {
2966
- const directory = _chunk7YHSD3Z6cjs.createRouteDirectoryPattern.call(void 0, route);
2921
+ const directory = _chunkGVNCWSQVcjs.createRouteDirectoryPattern.call(void 0, route);
2967
2922
  return directory === pattern ? {} : { directory };
2968
2923
  }
2969
2924
  _chunkS3JO3N4Hcjs.__name.call(void 0, getPageDirectoryField, "getPageDirectoryField");
@@ -3044,7 +2999,7 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, replaceAll, "replaceAll");
3044
2999
  async function safeGlobFiles(pattern, cwd) {
3045
3000
  try {
3046
3001
  return await _chunk5QIKR7RRcjs.globFiles.call(void 0, pattern, cwd);
3047
- } catch (e12) {
3002
+ } catch (e11) {
3048
3003
  return [];
3049
3004
  }
3050
3005
  }
@@ -3052,7 +3007,7 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, safeGlobFiles, "safeGlobFiles");
3052
3007
  function toRealPath(filePath) {
3053
3008
  try {
3054
3009
  return _fs.realpathSync.call(void 0, filePath);
3055
- } catch (e13) {
3010
+ } catch (e12) {
3056
3011
  return filePath;
3057
3012
  }
3058
3013
  }
@@ -3145,7 +3100,7 @@ function farmFontImportsPlugin(options = {}) {
3145
3100
  return;
3146
3101
  }
3147
3102
  const resource = registry.getDevResource(pathname);
3148
- if (!_optionalChain([resource, 'optionalAccess', _141 => _141.bytes])) {
3103
+ if (!_optionalChain([resource, 'optionalAccess', _143 => _143.bytes])) {
3149
3104
  next();
3150
3105
  return;
3151
3106
  }
@@ -3430,7 +3385,7 @@ ${FONT_SECTION_END}
3430
3385
  let url;
3431
3386
  try {
3432
3387
  url = new URL(input.source);
3433
- } catch (e14) {
3388
+ } catch (e13) {
3434
3389
  throw fontError(input.moduleId, `remoteFont() source must be an absolute HTTPS URL`);
3435
3390
  }
3436
3391
  if (url.protocol !== "https:") {
@@ -3674,7 +3629,7 @@ function readFontOptions(code, id, call) {
3674
3629
  const declaration = call.ancestors.at(-2);
3675
3630
  const statement = call.ancestors.at(-3);
3676
3631
  const statementParent = call.ancestors.at(-4);
3677
- const isModuleScope = _optionalChain([declaration, 'optionalAccess', _142 => _142.type]) === "VariableDeclaration" && (_optionalChain([statement, 'optionalAccess', _143 => _143.type]) === "Program" || _optionalChain([statement, 'optionalAccess', _144 => _144.type]) === "ExportNamedDeclaration" && _optionalChain([statementParent, 'optionalAccess', _145 => _145.type]) === "Program");
3632
+ const isModuleScope = _optionalChain([declaration, 'optionalAccess', _144 => _144.type]) === "VariableDeclaration" && (_optionalChain([statement, 'optionalAccess', _145 => _145.type]) === "Program" || _optionalChain([statement, 'optionalAccess', _146 => _146.type]) === "ExportNamedDeclaration" && _optionalChain([statementParent, 'optionalAccess', _147 => _147.type]) === "Program");
3678
3633
  if (!isModuleScope || call.ancestors.some((ancestor) => isFunctionNode(ancestor))) {
3679
3634
  throw fontError(id, `${call.kind}() must be declared directly at module scope`);
3680
3635
  }
@@ -3893,7 +3848,7 @@ function resolveLocalFontPath(source, importer, root) {
3893
3848
  }
3894
3849
  try {
3895
3850
  return _module.createRequire.call(void 0, _url.pathToFileURL.call(void 0, importer)).resolve(source);
3896
- } catch (e15) {
3851
+ } catch (e14) {
3897
3852
  const segments = source.replace(/\\/g, "/").split("/");
3898
3853
  if (segments.includes("..")) return path4.default.resolve(root, source);
3899
3854
  let current = path4.default.dirname(importer);
@@ -4258,7 +4213,7 @@ var _stream = require('stream');
4258
4213
 
4259
4214
  function resolveFarmNotFoundComponentPath(config, appDirs) {
4260
4215
  const extensions = _chunkPSV6XKPOcjs.getFarmRendererComponentExtensions.call(void 0, config.renderer);
4261
- const configuredPath = _optionalChain([config, 'access', _146 => _146.notFound, 'optionalAccess', _147 => _147.component, 'optionalAccess', _148 => _148.trim, 'call', _149 => _149()]);
4216
+ const configuredPath = _optionalChain([config, 'access', _148 => _148.notFound, 'optionalAccess', _149 => _149.component, 'optionalAccess', _150 => _150.trim, 'call', _151 => _151()]);
4262
4217
  if (configuredPath) {
4263
4218
  const componentPath = path4.default.isAbsolute(configuredPath) ? path4.default.normalize(configuredPath) : path4.default.resolve(config.root, configuredPath);
4264
4219
  if (!extensions.some((extension) => componentPath.endsWith(extension))) {
@@ -4461,7 +4416,7 @@ function normalizeStackPath(value) {
4461
4416
  const withoutQuery = value.replace(/[?#].*$/, "");
4462
4417
  try {
4463
4418
  return withoutQuery.startsWith("file://") ? _url.fileURLToPath.call(void 0, withoutQuery) : withoutQuery;
4464
- } catch (e16) {
4419
+ } catch (e15) {
4465
4420
  return void 0;
4466
4421
  }
4467
4422
  }
@@ -4507,7 +4462,7 @@ function createSourceFrame(location) {
4507
4462
  column: location.column,
4508
4463
  lines
4509
4464
  };
4510
- } catch (e17) {
4465
+ } catch (e16) {
4511
4466
  return void 0;
4512
4467
  }
4513
4468
  }
@@ -4531,6 +4486,8 @@ function createDefaultErrorDiagnostics(error, root) {
4531
4486
  _chunkS3JO3N4Hcjs.__name.call(void 0, createDefaultErrorDiagnostics, "createDefaultErrorDiagnostics");
4532
4487
 
4533
4488
  // src/server/renderer.ts
4489
+ _chunkAPDGOKKEcjs.installFarmIslandValues.call(void 0, );
4490
+ var islands;
4534
4491
  var cachedClerkProvider = null;
4535
4492
  var importRuntimeModule = new Function("specifier", "return import(specifier);");
4536
4493
  function shouldServePrerenderedPage(nodeEnv, method) {
@@ -4631,7 +4588,7 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, appendResponseVary, "appendResponseVary");
4631
4588
  function renderI18nAlternateLinks(requestPath, snapshot, options) {
4632
4589
  if (snapshot.routing === "none") return "";
4633
4590
  const url = new URL(requestPath, "http://farm.local");
4634
- return _chunk7YHSD3Z6cjs.renderFarmLocaleAlternateLinks.call(void 0, url.pathname, snapshot, options);
4591
+ return _chunkGVNCWSQVcjs.renderFarmLocaleAlternateLinks.call(void 0, url.pathname, snapshot, options);
4635
4592
  }
4636
4593
  _chunkS3JO3N4Hcjs.__name.call(void 0, renderI18nAlternateLinks, "renderI18nAlternateLinks");
4637
4594
  var PPR_REFRESH_MAX_ATTEMPTS = 3;
@@ -4730,12 +4687,12 @@ async function parseRouteModuleProps(routeModule, input) {
4730
4687
  }
4731
4688
  const schemas = routeModule.__farmRouteSchemas;
4732
4689
  const params = parseRouteModuleSchema(
4733
- _optionalChain([schemas, 'optionalAccess', _150 => _150.params]),
4690
+ _optionalChain([schemas, 'optionalAccess', _152 => _152.params]),
4734
4691
  input.props.params,
4735
4692
  "params",
4736
4693
  input.routePath
4737
4694
  );
4738
- const search = parseRouteModuleSchema(_optionalChain([schemas, 'optionalAccess', _151 => _151.search]), input.search, "search", input.routePath);
4695
+ const search = parseRouteModuleSchema(_optionalChain([schemas, 'optionalAccess', _153 => _153.search]), input.search, "search", input.routePath);
4739
4696
  return {
4740
4697
  ...input.props,
4741
4698
  params,
@@ -4772,7 +4729,7 @@ function readAppPackageIdentity(root) {
4772
4729
  return JSON.parse(
4773
4730
  fs5.readFileSync(path9.join(root || process.cwd(), "package.json"), "utf8")
4774
4731
  );
4775
- } catch (e18) {
4732
+ } catch (e17) {
4776
4733
  return {};
4777
4734
  }
4778
4735
  }
@@ -4790,7 +4747,11 @@ var _ServerRenderer = class _ServerRenderer {
4790
4747
  }
4791
4748
  async initialize() {
4792
4749
  if (this.rendererRuntime) return;
4793
- if (_optionalChain([this, 'access', _152 => _152.config, 'access', _153 => _153.notFound, 'optionalAccess', _154 => _154.component, 'optionalAccess', _155 => _155.trim, 'call', _156 => _156()])) {
4750
+ if (this.islandValues()) {
4751
+ (await import("./internal/islands-server.cjs")).installFarmIslandsServer();
4752
+ await _asyncNullishCoalesce(islands, async () => ( (islands = await import("./internal/islands-runtime.cjs"))));
4753
+ }
4754
+ if (_optionalChain([this, 'access', _154 => _154.config, 'access', _155 => _155.notFound, 'optionalAccess', _156 => _156.component, 'optionalAccess', _157 => _157.trim, 'call', _158 => _158()])) {
4794
4755
  resolveFarmNotFoundComponentPath(this.config, _chunkWBKEZXWEcjs.getFarmAppDirectories.call(void 0, this.config));
4795
4756
  }
4796
4757
  const loaded = _chunkPSV6XKPOcjs.isReactRenderer.call(void 0, this.config.renderer) ? await import("./renderer/react/server.cjs") : this.viteServer ? await _chunkPJ42JESYcjs.loadFarmDevModule.call(void 0, this.viteServer, this.config.renderer.server) : await import(_url.pathToFileURL.call(void 0,
@@ -4815,7 +4776,7 @@ var _ServerRenderer = class _ServerRenderer {
4815
4776
  "node"
4816
4777
  );
4817
4778
  this.rendererRuntime = runtime;
4818
- _optionalChain([this, 'access', _157 => _157.routeManager, 'access', _158 => _158.setRendererRuntime, 'optionalCall', _159 => _159(this.rendererRuntime)]);
4779
+ _optionalChain([this, 'access', _159 => _159.routeManager, 'access', _160 => _160.setRendererRuntime, 'optionalCall', _161 => _161(this.rendererRuntime)]);
4819
4780
  await this.applyRendererAppSetup();
4820
4781
  }
4821
4782
  /**
@@ -4872,7 +4833,7 @@ var _ServerRenderer = class _ServerRenderer {
4872
4833
  /// Stylesheets the app imported through JS (fontsource packages, component
4873
4834
  /// CSS) that the document must link alongside globals.css — see #658.
4874
4835
  collectDevStyleHrefs() {
4875
- const graph = _optionalChain([this, 'access', _160 => _160.viteServer, 'optionalAccess', _161 => _161.moduleGraph]);
4836
+ const graph = _optionalChain([this, 'access', _162 => _162.viteServer, 'optionalAccess', _163 => _163.moduleGraph]);
4876
4837
  if (!graph) return [];
4877
4838
  return collectDevStylesheetUrls(
4878
4839
  graph.idToModuleMap.values(),
@@ -4900,8 +4861,20 @@ var _ServerRenderer = class _ServerRenderer {
4900
4861
  if (!this.rendererRuntime.wrapClientGraph || typeof getIsolatedClientBoundaryModules !== "function" || getIsolatedClientBoundaryModules.call(this.routeManager, this.config.root).size === 0) {
4901
4862
  return element;
4902
4863
  }
4864
+ if (islands && this.islandValues())
4865
+ return islands.wrapFarmIsolatedClientGraph(void 0, element);
4903
4866
  return this.rendererRuntime.wrapClientGraph(element);
4904
4867
  }
4868
+ /** The page a hydrating layout keeps as server HTML: islands again, or a server tree. */
4869
+ async isolateServerPage(element, serverTree) {
4870
+ if (islands && this.islandValues()) {
4871
+ const runtime = islands;
4872
+ return serverTree ? runtime.renderFarmServerTreePage(void 0, element, {
4873
+ isolate: /* @__PURE__ */ _chunkS3JO3N4Hcjs.__name.call(void 0, (node) => runtime.isolateFarmServerPageGraph(void 0, node), "isolate")
4874
+ }) : runtime.isolateFarmServerPageGraph(void 0, element);
4875
+ }
4876
+ return serverTree && this.rendererRuntime.renderServerTreePage ? this.rendererRuntime.renderServerTreePage(element, { values: false }) : this.rendererRuntime.isolateServerPageGraph(element);
4877
+ }
4905
4878
  async renderElementToCompleteHTML(element, options = {}) {
4906
4879
  const streaming = _chunkPSV6XKPOcjs.getFarmRendererStreamingCapabilitiesForRuntime.call(void 0, this.config.renderer, "node");
4907
4880
  const renderToPipeableStream = streaming.node ? this.rendererRuntime.renderToPipeableStream : void 0;
@@ -4962,6 +4935,10 @@ var _ServerRenderer = class _ServerRenderer {
4962
4935
  }
4963
4936
  return { html: await this.renderElementToCompleteHTML(element, options), head: "" };
4964
4937
  }
4938
+ /** Islands mode sends large prop values once, keyed by content (RFC 0003). */
4939
+ islandValues() {
4940
+ return _chunkPDU4P2ICcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([this, 'access', _164 => _164.config, 'access', _165 => _165.experimental, 'optionalAccess', _166 => _166.serverComponents])) === "islands";
4941
+ }
4965
4942
  /**
4966
4943
  * Render the route tree used by client navigation without producing a second
4967
4944
  * document response. Layout markers let the browser preserve the longest
@@ -4988,7 +4965,7 @@ var _ServerRenderer = class _ServerRenderer {
4988
4965
  if (input.pageShouldHydrate && !input.layoutShouldHydrate) {
4989
4966
  element = this.wrapClientGraph(element);
4990
4967
  } else if (input.layoutShouldHydrate && !input.pageShouldHydrate && this.rendererRuntime.isolateServerPageGraph) {
4991
- element = input.serverTree && this.rendererRuntime.renderServerTreePage ? await this.rendererRuntime.renderServerTreePage(element) : this.rendererRuntime.isolateServerPageGraph(element);
4968
+ element = await this.isolateServerPage(element, input.serverTree === true);
4992
4969
  }
4993
4970
  element = this.createPageBoundary(element, {
4994
4971
  pageShouldHydrate: input.pageShouldHydrate,
@@ -5035,7 +5012,7 @@ var _ServerRenderer = class _ServerRenderer {
5035
5012
  async runWithRequestContext(request2, fn) {
5036
5013
  return _chunkZTP3BJG6cjs._runWithCurrentRequest.call(void 0,
5037
5014
  request2,
5038
- () => _optionalChain([this, 'access', _162 => _162.i18nRuntime, 'optionalAccess', _163 => _163.config, 'access', _164 => _164.enabled]) ? _chunkXJXBIP67cjs._runWithFarmI18nRequest.call(void 0, this.i18nRuntime, request2, fn, {
5015
+ () => _optionalChain([this, 'access', _167 => _167.i18nRuntime, 'optionalAccess', _168 => _168.config, 'access', _169 => _169.enabled]) ? _chunkXJXBIP67cjs._runWithFarmI18nRequest.call(void 0, this.i18nRuntime, request2, fn, {
5039
5016
  redirect: false
5040
5017
  }) : fn()
5041
5018
  );
@@ -5066,7 +5043,7 @@ var _ServerRenderer = class _ServerRenderer {
5066
5043
  * Check if a path should be served from SSG cache
5067
5044
  */
5068
5045
  async shouldServeSSG(pathname) {
5069
- const ssgPage = _chunkQEILRWVVcjs.matchSSGPage.call(void 0, pathname, this.ssgManifest);
5046
+ const ssgPage = _chunk3XEMGDBFcjs.matchSSGPage.call(void 0, pathname, this.ssgManifest);
5070
5047
  if (!ssgPage) return null;
5071
5048
  const cached = await this.getCachedSSGPage(pathname);
5072
5049
  if (cached && await this.dataCache.isStaleAsync(cached)) {
@@ -5183,7 +5160,7 @@ var _ServerRenderer = class _ServerRenderer {
5183
5160
  setImmediate(async () => {
5184
5161
  try {
5185
5162
  const mod = await this.routeManager.loadRouteModule(page.filePath);
5186
- if (!_optionalChain([mod, 'optionalAccess', _165 => _165.default])) return;
5163
+ if (!_optionalChain([mod, 'optionalAccess', _170 => _170.default])) return;
5187
5164
  const { route, layouts } = this.routeManager.matchRoute(page.urlPath);
5188
5165
  const layoutModules = await Promise.all(
5189
5166
  layouts.map((l) => this.routeManager.loadLayoutModule(l.modulePath))
@@ -5197,7 +5174,7 @@ var _ServerRenderer = class _ServerRenderer {
5197
5174
  };
5198
5175
  let pageElement = this.rendererRuntime.createElement(PageComponent, pageProps);
5199
5176
  const pageMetadata = _nullishCoalesce(routeManifest.routes.find(
5200
- (entry) => entry.pattern === _optionalChain([route, 'optionalAccess', _166 => _166.pattern])
5177
+ (entry) => entry.pattern === _optionalChain([route, 'optionalAccess', _171 => _171.pattern])
5201
5178
  ), () => ( {
5202
5179
  shouldHydrate: false,
5203
5180
  islandStrategy: null
@@ -5307,10 +5284,10 @@ var _ServerRenderer = class _ServerRenderer {
5307
5284
  res.setHeader(header.key, header.value);
5308
5285
  }
5309
5286
  const request2 = _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
5310
- trustProxy: _optionalChain([this, 'access', _167 => _167.config, 'access', _168 => _168.server, 'optionalAccess', _169 => _169.trustProxy])
5287
+ trustProxy: _optionalChain([this, 'access', _172 => _172.config, 'access', _173 => _173.server, 'optionalAccess', _174 => _174.trustProxy])
5311
5288
  });
5312
5289
  const runtime = this.i18nRuntime;
5313
- if (_optionalChain([runtime, 'optionalAccess', _170 => _170.config, 'access', _171 => _171.enabled])) {
5290
+ if (_optionalChain([runtime, 'optionalAccess', _175 => _175.config, 'access', _176 => _176.enabled])) {
5314
5291
  const resolution = runtime.resolveRequest(request2);
5315
5292
  const varyHeaders = _chunkQCVE2OCIcjs.getFarmLocaleVaryHeaders.call(void 0, runtime.config, resolution);
5316
5293
  for (const header of varyHeaders) appendResponseVary(res, header);
@@ -5356,7 +5333,7 @@ var _ServerRenderer = class _ServerRenderer {
5356
5333
  });
5357
5334
  }, "completeRender");
5358
5335
  try {
5359
- const url = _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, { trustProxy: _optionalChain([this, 'access', _172 => _172.config, 'access', _173 => _173.server, 'optionalAccess', _174 => _174.trustProxy]) });
5336
+ const url = _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, { trustProxy: _optionalChain([this, 'access', _177 => _177.config, 'access', _178 => _178.server, 'optionalAccess', _179 => _179.trustProxy]) });
5360
5337
  pathname = url.pathname;
5361
5338
  _chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "render.start", route: pathname, pathname });
5362
5339
  searchParamsObject = _chunkQNPEUFHQcjs.searchParamsToObject.call(void 0, url.searchParams);
@@ -5435,6 +5412,25 @@ var _ServerRenderer = class _ServerRenderer {
5435
5412
  route: route.pattern,
5436
5413
  params
5437
5414
  });
5415
+ let actionRequest;
5416
+ if (req.method === "POST" && _chunkPDU4P2ICcjs.resolveFarmServerComponentsMode.call(void 0, _optionalChain([this, 'access', _180 => _180.config, 'access', _181 => _181.experimental, 'optionalAccess', _182 => _182.serverComponents])) === "islands") {
5417
+ await Promise.all([
5418
+ this.routeManager.loadRouteModule(route.modulePath),
5419
+ ...layouts.map((layout) => this.routeManager.loadLayoutModule(layout.modulePath))
5420
+ ]);
5421
+ actionRequest = _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
5422
+ trustProxy: _optionalChain([this, 'access', _183 => _183.config, 'access', _184 => _184.server, 'optionalAccess', _185 => _185.trustProxy])
5423
+ });
5424
+ const actionResponse = await _chunk3BROEWFYcjs.handleFarmFormActionRequest.call(void 0,
5425
+ actionRequest,
5426
+ _chunkP4TYB4SFcjs.resolveServerActionsConfig.call(void 0, this.config.serverActions)
5427
+ );
5428
+ if (actionResponse) {
5429
+ await _chunkUQZ4AYTHcjs.sendWebResponse.call(void 0, res, actionResponse);
5430
+ completeRender(actionResponse.status, route.pattern);
5431
+ return;
5432
+ }
5433
+ }
5438
5434
  const loadingBoundaryEntry = this.routeManager.getMatchingLoading(pathname, route);
5439
5435
  errorBoundaryEntry = this.routeManager.getMatchingError(pathname, route);
5440
5436
  middlewareMap = toMiddlewareMap(req.__FARM_MIDDLEWARE_DATA__);
@@ -5442,9 +5438,9 @@ var _ServerRenderer = class _ServerRenderer {
5442
5438
  pluginExposedContext = _chunk4TLUFAIPcjs.getRequestContextSnapshot.call(void 0, req, {
5443
5439
  exposedOnly: true
5444
5440
  });
5445
- const currentRequest = _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
5446
- trustProxy: _optionalChain([this, 'access', _175 => _175.config, 'access', _176 => _176.server, 'optionalAccess', _177 => _177.trustProxy])
5447
- });
5441
+ const currentRequest = _nullishCoalesce(actionRequest, () => ( _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
5442
+ trustProxy: _optionalChain([this, 'access', _186 => _186.config, 'access', _187 => _187.server, 'optionalAccess', _188 => _188.trustProxy])
5443
+ })));
5448
5444
  const routeContext = await this.resolveRouteContext({
5449
5445
  request: currentRequest,
5450
5446
  rawRequest: req,
@@ -5485,11 +5481,11 @@ var _ServerRenderer = class _ServerRenderer {
5485
5481
  searchParams: Promise.resolve(searchParamsObject),
5486
5482
  error
5487
5483
  };
5488
- if (_chunkOX6O6WVAcjs.isFarmNotFoundError.call(void 0, error) && _optionalChain([programmaticRouteComponents, 'optionalAccess', _178 => _178.notFound])) {
5484
+ if (_chunkOX6O6WVAcjs.isFarmNotFoundError.call(void 0, error) && _optionalChain([programmaticRouteComponents, 'optionalAccess', _189 => _189.notFound])) {
5489
5485
  res.statusCode = 404;
5490
5486
  PageComponent = programmaticRouteComponents.notFound;
5491
5487
  pageProps = routeStateProps;
5492
- } else if (_optionalChain([programmaticRouteComponents, 'optionalAccess', _179 => _179.error])) {
5488
+ } else if (_optionalChain([programmaticRouteComponents, 'optionalAccess', _190 => _190.error])) {
5493
5489
  res.statusCode = 500;
5494
5490
  PageComponent = programmaticRouteComponents.error;
5495
5491
  pageProps = routeStateProps;
@@ -5497,10 +5493,10 @@ var _ServerRenderer = class _ServerRenderer {
5497
5493
  throw error;
5498
5494
  }
5499
5495
  }
5500
- const renderingConfig = await _chunkQEILRWVVcjs.resolveRouteRenderingConfigFromFile.call(void 0,
5496
+ const renderingConfig = await _chunk3XEMGDBFcjs.resolveRouteRenderingConfigFromFile.call(void 0,
5501
5497
  routeModule,
5502
5498
  route.modulePath,
5503
- { experimentalPPR: _optionalChain([this, 'access', _180 => _180.config, 'access', _181 => _181.experimental, 'optionalAccess', _182 => _182.ppr]) === true }
5499
+ { experimentalPPR: _optionalChain([this, 'access', _191 => _191.config, 'access', _192 => _192.experimental, 'optionalAccess', _193 => _193.ppr]) === true }
5504
5500
  );
5505
5501
  const pprBypassReason = renderingConfig.ppr ? this.getPPRShellBypassReason(req, middlewareMap, middlewareContext, pluginExposedContext) : void 0;
5506
5502
  const canCachePPRShell = renderingConfig.ppr && !pprBypassReason;
@@ -5508,7 +5504,7 @@ var _ServerRenderer = class _ServerRenderer {
5508
5504
  const pprShellOptions = canCachePPRShell ? {
5509
5505
  pathname,
5510
5506
  search: url.search,
5511
- locale: _nullishCoalesce(_optionalChain([pprI18nSnapshot, 'optionalAccess', _183 => _183.locale]), () => ( "")),
5507
+ locale: _nullishCoalesce(_optionalChain([pprI18nSnapshot, 'optionalAccess', _194 => _194.locale]), () => ( "")),
5512
5508
  origin: pprI18nSnapshot && pprI18nSnapshot.routing !== "none" ? url.origin : "",
5513
5509
  revalidate: renderingConfig.revalidate
5514
5510
  } : void 0;
@@ -5631,20 +5627,20 @@ var _ServerRenderer = class _ServerRenderer {
5631
5627
  if (moduleMetadata.suppressedAsyncHydration) {
5632
5628
  warnSuppressedAsyncHydrationOnce(
5633
5629
  route.modulePath,
5634
- _optionalChain([routeManifestEntry, 'optionalAccess', _184 => _184.suppressedAsyncHydrationReason])
5630
+ _optionalChain([routeManifestEntry, 'optionalAccess', _195 => _195.suppressedAsyncHydrationReason])
5635
5631
  );
5636
5632
  }
5637
5633
  const layoutHydrationMetadata = layouts.map((layout) => {
5638
5634
  const manifestEntry = routeManifest.layouts.find(
5639
5635
  (entry) => entry.pattern === layout.pattern
5640
5636
  );
5641
- if (_optionalChain([manifestEntry, 'optionalAccess', _185 => _185.suppressedAsyncHydration])) {
5637
+ if (_optionalChain([manifestEntry, 'optionalAccess', _196 => _196.suppressedAsyncHydration])) {
5642
5638
  warnSuppressedAsyncHydrationOnce(
5643
5639
  layout.modulePath,
5644
5640
  manifestEntry.suppressedAsyncHydrationReason
5645
5641
  );
5646
5642
  }
5647
- if (typeof _optionalChain([manifestEntry, 'optionalAccess', _186 => _186.shouldHydrate]) === "boolean") {
5643
+ if (typeof _optionalChain([manifestEntry, 'optionalAccess', _197 => _197.shouldHydrate]) === "boolean") {
5648
5644
  return {
5649
5645
  isClientComponent: manifestEntry.isClientComponent === true,
5650
5646
  shouldHydrate: manifestEntry.shouldHydrate,
@@ -5664,9 +5660,9 @@ var _ServerRenderer = class _ServerRenderer {
5664
5660
  const clientLayouts = layouts.map((layout, index) => ({
5665
5661
  pattern: layout.pattern,
5666
5662
  modulePath: _chunk5QIKR7RRcjs.toViteModuleId.call(void 0, layout.modulePath, this.config.root),
5667
- shouldHydrate: _optionalChain([layoutHydrationMetadata, 'access', _187 => _187[index], 'optionalAccess', _188 => _188.shouldHydrate]) === true,
5668
- islandStrategy: _nullishCoalesce(_optionalChain([layoutHydrationMetadata, 'access', _189 => _189[index], 'optionalAccess', _190 => _190.islandStrategy]), () => ( null)),
5669
- ..._optionalChain([layoutHydrationMetadata, 'access', _191 => _191[index], 'optionalAccess', _192 => _192.hasIsolatedClientBoundaries]) === true ? { hasIsolatedClientBoundaries: true } : {}
5663
+ shouldHydrate: _optionalChain([layoutHydrationMetadata, 'access', _198 => _198[index], 'optionalAccess', _199 => _199.shouldHydrate]) === true,
5664
+ islandStrategy: _nullishCoalesce(_optionalChain([layoutHydrationMetadata, 'access', _200 => _200[index], 'optionalAccess', _201 => _201.islandStrategy]), () => ( null)),
5665
+ ..._optionalChain([layoutHydrationMetadata, 'access', _202 => _202[index], 'optionalAccess', _203 => _203.hasIsolatedClientBoundaries]) === true ? { hasIsolatedClientBoundaries: true } : {}
5670
5666
  }));
5671
5667
  const hydrationStrategies = [
5672
5668
  ...shouldHydrate && moduleMetadata.islandStrategy ? [moduleMetadata.islandStrategy] : [],
@@ -5680,7 +5676,7 @@ var _ServerRenderer = class _ServerRenderer {
5680
5676
  const hasHydratableRouteSlots = renderedRouteSlots.some(
5681
5677
  (slot) => slot.isClientComponent || slot.shouldHydrate
5682
5678
  );
5683
- const hasIsolatedClientBoundaries = _optionalChain([routeManifestEntry, 'optionalAccess', _193 => _193.hasIsolatedClientBoundaries]) === true || layoutHydrationMetadata.some((metadata) => metadata.hasIsolatedClientBoundaries === true);
5679
+ const hasIsolatedClientBoundaries = _optionalChain([routeManifestEntry, 'optionalAccess', _204 => _204.hasIsolatedClientBoundaries]) === true || layoutHydrationMetadata.some((metadata) => metadata.hasIsolatedClientBoundaries === true);
5684
5680
  req.__FARM_PAGE_PATH__ = route.modulePath;
5685
5681
  req.__FARM_ROUTE__ = pathname;
5686
5682
  req.__FARM_IS_CLIENT_COMPONENT__ = isClientComponent;
@@ -5693,7 +5689,7 @@ var _ServerRenderer = class _ServerRenderer {
5693
5689
  req.__FARM_SHOULD_HYDRATE__ = shouldHydrate || shouldHydrateLayout || hasIsolatedClientBoundaries;
5694
5690
  req.__FARM_ISLAND_STRATEGY__ = hydrationIslandStrategy;
5695
5691
  req.__FARM_HAS_HYDRATABLE_ROUTE_SLOTS__ = hasHydratableRouteSlots;
5696
- req.__FARM_LOADING_MODULE_PATH__ = _optionalChain([loadingBoundaryEntry, 'optionalAccess', _194 => _194.modulePath]) ? _chunk5QIKR7RRcjs.toViteModuleId.call(void 0, loadingBoundaryEntry.modulePath, this.config.root) : null;
5692
+ req.__FARM_LOADING_MODULE_PATH__ = _optionalChain([loadingBoundaryEntry, 'optionalAccess', _205 => _205.modulePath]) ? _chunk5QIKR7RRcjs.toViteModuleId.call(void 0, loadingBoundaryEntry.modulePath, this.config.root) : null;
5697
5693
  req.__FARM_ROUTE_SLOTS__ = renderedRouteSlots.map((slot) => ({
5698
5694
  name: slot.name,
5699
5695
  ownerPattern: slot.ownerPattern,
@@ -5763,7 +5759,10 @@ var _ServerRenderer = class _ServerRenderer {
5763
5759
  if ((isClientComponent || shouldHydrate) && !shouldHydrateLayout) {
5764
5760
  pageElement = this.wrapClientGraph(pageElement);
5765
5761
  } else if (shouldHydrateLayout && !(isClientComponent || shouldHydrate) && this.rendererRuntime.isolateServerPageGraph) {
5766
- pageElement = _optionalChain([routeManifestEntry, 'optionalAccess', _195 => _195.serverTree]) === true && this.rendererRuntime.renderServerTreePage ? await this.rendererRuntime.renderServerTreePage(pageElement) : this.rendererRuntime.isolateServerPageGraph(pageElement);
5762
+ pageElement = await this.isolateServerPage(
5763
+ pageElement,
5764
+ _optionalChain([routeManifestEntry, 'optionalAccess', _206 => _206.serverTree]) === true
5765
+ );
5767
5766
  }
5768
5767
  pageElement = this.createPageBoundary(pageElement, {
5769
5768
  pageShouldHydrate: isClientComponent || shouldHydrate,
@@ -5920,7 +5919,7 @@ var _ServerRenderer = class _ServerRenderer {
5920
5919
  }
5921
5920
  }
5922
5921
  _chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "render.error", route: pathname, error });
5923
- const errorStatus = _chunk7YHSD3Z6cjs.resolveDefaultErrorStatus.call(void 0, error);
5922
+ const errorStatus = _chunkGVNCWSQVcjs.resolveDefaultErrorStatus.call(void 0, error);
5924
5923
  if (pprRefreshRoute) {
5925
5924
  _chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
5926
5925
  type: "ppr.refresh.error",
@@ -5964,7 +5963,7 @@ var _ServerRenderer = class _ServerRenderer {
5964
5963
  const rendererCapabilities = _chunkPSV6XKPOcjs.getFarmRendererCapabilities.call(void 0, this.config.renderer);
5965
5964
  if (!rendererCapabilities.functionComponents) {
5966
5965
  throw new Error(
5967
- `Integration provider \`${provider.name}\` requires a renderer that can host function components; \`${_nullishCoalesce(_optionalChain([this, 'access', _196 => _196.config, 'access', _197 => _197.renderer, 'optionalAccess', _198 => _198.name]), () => ( "the configured renderer"))}\` cannot.`
5966
+ `Integration provider \`${provider.name}\` requires a renderer that can host function components; \`${_nullishCoalesce(_optionalChain([this, 'access', _207 => _207.config, 'access', _208 => _208.renderer, 'optionalAccess', _209 => _209.name]), () => ( "the configured renderer"))}\` cannot.`
5968
5967
  );
5969
5968
  }
5970
5969
  if (provider.type === "clerk" && !_chunkPSV6XKPOcjs.isReactRenderer.call(void 0, this.config.renderer)) {
@@ -6003,7 +6002,7 @@ var _ServerRenderer = class _ServerRenderer {
6003
6002
  }
6004
6003
  if (provider.type !== "clerk" && typeof this.rendererRuntime.markFunctionComponent === "function" && !isRendererCompiledComponent(
6005
6004
  _nullishCoalesce(providerSourceModule, () => ( "")),
6006
- _chunkPSV6XKPOcjs.resolveFarmComponentExtensions.call(void 0, _optionalChain([this, 'access', _199 => _199.config, 'access', _200 => _200.renderer, 'optionalAccess', _201 => _201.componentExtensions]))
6005
+ _chunkPSV6XKPOcjs.resolveFarmComponentExtensions.call(void 0, _optionalChain([this, 'access', _210 => _210.config, 'access', _211 => _211.renderer, 'optionalAccess', _212 => _212.componentExtensions]))
6007
6006
  )) {
6008
6007
  ProviderComponent = this.rendererRuntime.markFunctionComponent(ProviderComponent);
6009
6008
  }
@@ -6130,7 +6129,7 @@ var _ServerRenderer = class _ServerRenderer {
6130
6129
  );
6131
6130
  }
6132
6131
  const request2 = _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
6133
- trustProxy: _optionalChain([this, 'access', _202 => _202.config, 'access', _203 => _203.server, 'optionalAccess', _204 => _204.trustProxy])
6132
+ trustProxy: _optionalChain([this, 'access', _213 => _213.config, 'access', _214 => _214.server, 'optionalAccess', _215 => _215.trustProxy])
6134
6133
  });
6135
6134
  const url = new URL(request2.url);
6136
6135
  const llmsContext = match.metadata.kind === "llms" || match.metadata.kind === "llms-full" ? await this.createLlmsTxtContext(request2, {
@@ -6148,7 +6147,7 @@ var _ServerRenderer = class _ServerRenderer {
6148
6147
  origin: url.origin,
6149
6148
  readMarkdown: llmsContext.markdown
6150
6149
  }) : value;
6151
- const response = _chunk7YHSD3Z6cjs.createFarmMetadataRouteResponse.call(void 0, match.metadata.kind, body, routeModule, {
6150
+ const response = _chunkGVNCWSQVcjs.createFarmMetadataRouteResponse.call(void 0, match.metadata.kind, body, routeModule, {
6152
6151
  method,
6153
6152
  request: request2
6154
6153
  });
@@ -6166,7 +6165,7 @@ var _ServerRenderer = class _ServerRenderer {
6166
6165
  }
6167
6166
  /** `/llms.txt` and `/llms-full.txt` from `agent.llmsTxt` when no file route owns them. */
6168
6167
  getGeneratedLlmsKind(pathname) {
6169
- const config = _chunkD5IHNDHIcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([this, 'access', _205 => _205.config, 'access', _206 => _206.agent, 'optionalAccess', _207 => _207.llmsTxt]));
6168
+ const config = _chunkD5IHNDHIcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([this, 'access', _216 => _216.config, 'access', _217 => _217.agent, 'optionalAccess', _218 => _218.llmsTxt]));
6170
6169
  if (!config.enabled) return null;
6171
6170
  if (pathname === "/llms.txt") return "llms";
6172
6171
  return pathname === "/llms-full.txt" && config.full ? "llms-full" : null;
@@ -6174,9 +6173,9 @@ var _ServerRenderer = class _ServerRenderer {
6174
6173
  async renderGeneratedLlmsTxt(req, res, kind) {
6175
6174
  try {
6176
6175
  const request2 = _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
6177
- trustProxy: _optionalChain([this, 'access', _208 => _208.config, 'access', _209 => _209.server, 'optionalAccess', _210 => _210.trustProxy])
6176
+ trustProxy: _optionalChain([this, 'access', _219 => _219.config, 'access', _220 => _220.server, 'optionalAccess', _221 => _221.trustProxy])
6178
6177
  });
6179
- const config = _chunkD5IHNDHIcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([this, 'access', _211 => _211.config, 'access', _212 => _212.agent, 'optionalAccess', _213 => _213.llmsTxt]));
6178
+ const config = _chunkD5IHNDHIcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([this, 'access', _222 => _222.config, 'access', _223 => _223.agent, 'optionalAccess', _224 => _224.llmsTxt]));
6180
6179
  const context = await this.createLlmsTxtContext(request2, { full: kind === "llms-full", req });
6181
6180
  const body = kind === "llms-full" ? await _chunkD5IHNDHIcjs.renderFarmLlmsFullTxt.call(void 0, context.defaults, {
6182
6181
  origin: new URL(request2.url).origin,
@@ -6184,7 +6183,7 @@ var _ServerRenderer = class _ServerRenderer {
6184
6183
  }) : context.defaults;
6185
6184
  await _chunkUQZ4AYTHcjs.sendWebResponse.call(void 0,
6186
6185
  res,
6187
- _chunk7YHSD3Z6cjs.createFarmMetadataRouteResponse.call(void 0,
6186
+ _chunkGVNCWSQVcjs.createFarmMetadataRouteResponse.call(void 0,
6188
6187
  kind,
6189
6188
  body,
6190
6189
  { revalidate: config.revalidate },
@@ -6203,23 +6202,23 @@ var _ServerRenderer = class _ServerRenderer {
6203
6202
  }
6204
6203
  }
6205
6204
  getAgentCrawlers() {
6206
- return _chunkJAXDRRRCcjs.resolveFarmAgentCrawlers.call(void 0, _optionalChain([this, 'access', _214 => _214.config, 'access', _215 => _215.agent, 'optionalAccess', _216 => _216.crawlers]));
6205
+ return _chunkJAXDRRRCcjs.resolveFarmAgentCrawlers.call(void 0, _optionalChain([this, 'access', _225 => _225.config, 'access', _226 => _226.agent, 'optionalAccess', _227 => _227.crawlers]));
6207
6206
  }
6208
6207
  /** `/robots.txt` from `agent.crawlers` when no robots.ts owns it. */
6209
6208
  async renderGeneratedRobotsTxt(req, res) {
6210
6209
  try {
6211
- const sitemapPath = _optionalChain([this, 'access', _217 => _217.routeManager, 'access', _218 => _218.matchMetadataRoute, 'call', _219 => _219("/sitemap.xml"), 'optionalAccess', _220 => _220.metadata, 'access', _221 => _221.kind]) === "sitemap" || this.getAgentSitemap().enabled ? "/sitemap.xml" : void 0;
6210
+ const sitemapPath = _optionalChain([this, 'access', _228 => _228.routeManager, 'access', _229 => _229.matchMetadataRoute, 'call', _230 => _230("/sitemap.xml"), 'optionalAccess', _231 => _231.metadata, 'access', _232 => _232.kind]) === "sitemap" || this.getAgentSitemap().enabled ? "/sitemap.xml" : void 0;
6212
6211
  const rootLayout = this.routeManager.getLayouts().get("/");
6213
6212
  const rootMetadata = sitemapPath && rootLayout ? (await this.routeManager.loadLayoutModule(rootLayout.modulePath)).metadata : void 0;
6214
6213
  const robots = _chunkJAXDRRRCcjs.createFarmAgentRobots.call(void 0, {
6215
6214
  crawlers: this.getAgentCrawlers(),
6216
6215
  sitemapPath,
6217
- metadataBase: _optionalChain([rootMetadata, 'optionalAccess', _222 => _222.metadataBase]),
6216
+ metadataBase: _optionalChain([rootMetadata, 'optionalAccess', _233 => _233.metadataBase]),
6218
6217
  basePath: this.config.basePath
6219
6218
  });
6220
6219
  await _chunkUQZ4AYTHcjs.sendWebResponse.call(void 0,
6221
6220
  res,
6222
- _chunk7YHSD3Z6cjs.createFarmMetadataRouteResponse.call(void 0, "robots", robots, {}, { method: req.method })
6221
+ _chunkGVNCWSQVcjs.createFarmMetadataRouteResponse.call(void 0, "robots", robots, {}, { method: req.method })
6223
6222
  );
6224
6223
  } catch (error) {
6225
6224
  _chunk5QIKR7RRcjs.logger.error(`Generated robots.txt failed: ${error}`);
@@ -6233,13 +6232,13 @@ var _ServerRenderer = class _ServerRenderer {
6233
6232
  }
6234
6233
  }
6235
6234
  getAgentSitemap() {
6236
- return _chunkJAXDRRRCcjs.resolveFarmAgentSitemap.call(void 0, _optionalChain([this, 'access', _223 => _223.config, 'access', _224 => _224.agent, 'optionalAccess', _225 => _225.sitemap]));
6235
+ return _chunkJAXDRRRCcjs.resolveFarmAgentSitemap.call(void 0, _optionalChain([this, 'access', _234 => _234.config, 'access', _235 => _235.agent, 'optionalAccess', _236 => _236.sitemap]));
6237
6236
  }
6238
6237
  /** `/sitemap.xml` from `agent.sitemap` when no sitemap.ts owns it. */
6239
6238
  async renderGeneratedSitemap(req, res) {
6240
6239
  try {
6241
6240
  const request2 = _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, {
6242
- trustProxy: _optionalChain([this, 'access', _226 => _226.config, 'access', _227 => _227.server, 'optionalAccess', _228 => _228.trustProxy])
6241
+ trustProxy: _optionalChain([this, 'access', _237 => _237.config, 'access', _238 => _238.server, 'optionalAccess', _239 => _239.trustProxy])
6243
6242
  });
6244
6243
  const sources = await Promise.all(
6245
6244
  this.getAgentListedRoutes().map(async ([pattern, route]) => {
@@ -6250,7 +6249,7 @@ var _ServerRenderer = class _ServerRenderer {
6250
6249
  }),
6251
6250
  fs5.promises.stat(route.modulePath).catch(() => void 0)
6252
6251
  ]);
6253
- return { pattern, module, lastModified: _optionalChain([stat, 'optionalAccess', _229 => _229.mtime, 'access', _230 => _230.toISOString, 'call', _231 => _231()]) };
6252
+ return { pattern, module, lastModified: _optionalChain([stat, 'optionalAccess', _240 => _240.mtime, 'access', _241 => _241.toISOString, 'call', _242 => _242()]) };
6254
6253
  })
6255
6254
  );
6256
6255
  const rootLayout = this.routeManager.getLayouts().get("/");
@@ -6258,12 +6257,12 @@ var _ServerRenderer = class _ServerRenderer {
6258
6257
  const sitemap = _chunkJAXDRRRCcjs.createFarmDefaultSitemap.call(void 0, sources, {
6259
6258
  origin: new URL(request2.url).origin,
6260
6259
  config: this.getAgentSitemap(),
6261
- metadataBase: _optionalChain([rootMetadata, 'optionalAccess', _232 => _232.metadataBase]),
6260
+ metadataBase: _optionalChain([rootMetadata, 'optionalAccess', _243 => _243.metadataBase]),
6262
6261
  basePath: this.config.basePath
6263
6262
  });
6264
6263
  await _chunkUQZ4AYTHcjs.sendWebResponse.call(void 0,
6265
6264
  res,
6266
- _chunk7YHSD3Z6cjs.createFarmMetadataRouteResponse.call(void 0, "sitemap", sitemap, {}, { method: req.method })
6265
+ _chunkGVNCWSQVcjs.createFarmMetadataRouteResponse.call(void 0, "sitemap", sitemap, {}, { method: req.method })
6267
6266
  );
6268
6267
  } catch (error) {
6269
6268
  _chunk5QIKR7RRcjs.logger.error(`Generated sitemap.xml failed: ${error}`);
@@ -6290,9 +6289,9 @@ var _ServerRenderer = class _ServerRenderer {
6290
6289
  * matcher) covers, as the production build decides.
6291
6290
  */
6292
6291
  getAgentListedRoutes() {
6293
- const guards = { config: this.config, middlewareRoutes: _nullishCoalesce(_optionalChain([this, 'access', _233 => _233.middlewareRoutes, 'optionalCall', _234 => _234()]), () => ( [])) };
6292
+ const guards = { config: this.config, middlewareRoutes: _nullishCoalesce(_optionalChain([this, 'access', _244 => _244.middlewareRoutes, 'optionalCall', _245 => _245()]), () => ( [])) };
6294
6293
  return [...this.routeManager.getRoutes()].filter(
6295
- ([pattern]) => !pattern.includes("[") && !_chunk7YHSD3Z6cjs.farmPathGuardCoversPage.call(void 0, guards, pattern)
6294
+ ([pattern]) => !pattern.includes("[") && !_chunkGVNCWSQVcjs.farmPathGuardCoversPage.call(void 0, guards, pattern)
6296
6295
  );
6297
6296
  }
6298
6297
  /**
@@ -6301,18 +6300,18 @@ var _ServerRenderer = class _ServerRenderer {
6301
6300
  * or a registered server such as the docs engine's. Production applies the same rules.
6302
6301
  */
6303
6302
  getDefaultMCPServer() {
6304
- if (_optionalChain([this, 'access', _235 => _235.config, 'access', _236 => _236.agent, 'optionalAccess', _237 => _237.mcp]) !== true || _chunkBMOBTMDRcjs.farmConfigMountsMCP.call(void 0, this.config)) return void 0;
6305
- if (_optionalChain([this, 'access', _238 => _238.apiRouteExists, 'optionalCall', _239 => _239("/api/mcp")])) return void 0;
6303
+ if (_optionalChain([this, 'access', _246 => _246.config, 'access', _247 => _247.agent, 'optionalAccess', _248 => _248.mcp]) !== true || _chunkBMOBTMDRcjs.farmConfigMountsMCP.call(void 0, this.config)) return void 0;
6304
+ if (_optionalChain([this, 'access', _249 => _249.apiRouteExists, 'optionalCall', _250 => _250("/api/mcp")])) return void 0;
6306
6305
  if (this.routeManager.matchRoute(_chunkBMOBTMDRcjs.FARM_DEFAULT_MCP_PATH).route) return void 0;
6307
6306
  _nullishCoalesce(this.defaultMCPServer, () => ( (this.defaultMCPServer = _chunkBMOBTMDRcjs.createFarmDefaultMCPServer.call(void 0,
6308
6307
  readAppPackageIdentity(this.config.root),
6309
- _chunkAHFRQMRXcjs.FARM_VERSION
6308
+ _chunkYBDSTNMHcjs.FARM_VERSION
6310
6309
  ))));
6311
6310
  return _chunkBMOBTMDRcjs.resolveFarmDefaultMCPServer.call(void 0, this.defaultMCPServer);
6312
6311
  }
6313
6312
  async renderDefaultMCP(req, res) {
6314
6313
  const server = this.getDefaultMCPServer();
6315
- const request2 = _nullishCoalesce(_chunkZTP3BJG6cjs.getCurrentRequestOrNull.call(void 0, ), () => ( _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, { trustProxy: _optionalChain([this, 'access', _240 => _240.config, 'access', _241 => _241.server, 'optionalAccess', _242 => _242.trustProxy]) })));
6314
+ const request2 = _nullishCoalesce(_chunkZTP3BJG6cjs.getCurrentRequestOrNull.call(void 0, ), () => ( _chunkZTP3BJG6cjs.createWebRequestFromFarmRequest.call(void 0, req, { trustProxy: _optionalChain([this, 'access', _251 => _251.config, 'access', _252 => _252.server, 'optionalAccess', _253 => _253.trustProxy]) })));
6316
6315
  try {
6317
6316
  const { handleFarmDefaultMCPRequest } = await import("./agent-mcp-handler-YKG7KVCY.cjs");
6318
6317
  const origin = new URL(request2.url).origin;
@@ -6355,7 +6354,7 @@ var _ServerRenderer = class _ServerRenderer {
6355
6354
  }
6356
6355
  /** Same inputs the production server gives llms.txt: static pages and root metadata. */
6357
6356
  async createLlmsTxtContext(request2, options = {}) {
6358
- const config = _chunkD5IHNDHIcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([this, 'access', _243 => _243.config, 'access', _244 => _244.agent, 'optionalAccess', _245 => _245.llmsTxt]));
6357
+ const config = _chunkD5IHNDHIcjs.resolveFarmLlmsTxtConfig.call(void 0, _optionalChain([this, 'access', _254 => _254.config, 'access', _255 => _255.agent, 'optionalAccess', _256 => _256.llmsTxt]));
6359
6358
  const origin = new URL(request2.url).origin;
6360
6359
  const sources = await Promise.all(
6361
6360
  this.getAgentListedRoutes().map(async ([pattern, route]) => {
@@ -6388,7 +6387,7 @@ var _ServerRenderer = class _ServerRenderer {
6388
6387
  pages,
6389
6388
  config,
6390
6389
  rootMetadata,
6391
- mcp: _optionalChain([this, 'access', _246 => _246.config, 'access', _247 => _247.agent, 'optionalAccess', _248 => _248.aiCatalog]) === false ? [] : _chunk7YHSD3Z6cjs.listFarmMCPLlmsTxtLinks.call(void 0, origin, {
6390
+ mcp: _optionalChain([this, 'access', _257 => _257.config, 'access', _258 => _258.agent, 'optionalAccess', _259 => _259.aiCatalog]) === false ? [] : _chunkGVNCWSQVcjs.listFarmMCPLlmsTxtLinks.call(void 0, origin, {
6392
6391
  basePath: this.config.basePath,
6393
6392
  apiServerBasePath: _chunkKNBBQHO2cjs.resolveFarmAPIServerBasePath.call(void 0,
6394
6393
  _chunkS3A45T7Fcjs.normalizeFarmAPIConfig.call(void 0,
@@ -6411,8 +6410,8 @@ var _ServerRenderer = class _ServerRenderer {
6411
6410
  * body is discarded.
6412
6411
  */
6413
6412
  createDevMarkdownReader(req) {
6414
- const socket = _optionalChain([req, 'optionalAccess', _249 => _249.socket]);
6415
- if (_optionalChain([req, 'optionalAccess', _250 => _250.method, 'optionalAccess', _251 => _251.toUpperCase, 'call', _252 => _252()]) === "HEAD" || !_optionalChain([socket, 'optionalAccess', _253 => _253.localAddress]) || !socket.localPort) {
6413
+ const socket = _optionalChain([req, 'optionalAccess', _260 => _260.socket]);
6414
+ if (_optionalChain([req, 'optionalAccess', _261 => _261.method, 'optionalAccess', _262 => _262.toUpperCase, 'call', _263 => _263()]) === "HEAD" || !_optionalChain([socket, 'optionalAccess', _264 => _264.localAddress]) || !socket.localPort) {
6416
6415
  return async () => null;
6417
6416
  }
6418
6417
  if (socket.encrypted) {
@@ -6477,7 +6476,7 @@ var _ServerRenderer = class _ServerRenderer {
6477
6476
  }
6478
6477
  const etag = `"${image.staticInfo.hash}"`;
6479
6478
  const requestUrl = _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, {
6480
- trustProxy: _optionalChain([this, 'access', _254 => _254.config, 'access', _255 => _255.server, 'optionalAccess', _256 => _256.trustProxy])
6479
+ trustProxy: _optionalChain([this, 'access', _265 => _265.config, 'access', _266 => _266.server, 'optionalAccess', _267 => _267.trustProxy])
6481
6480
  });
6482
6481
  const isVersioned = requestUrl.searchParams.get("v") === image.staticInfo.hash;
6483
6482
  res.setHeader("Content-Type", image.staticInfo.contentType);
@@ -6655,7 +6654,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6655
6654
  </script>`);
6656
6655
  const deferredScript = farmScripts(createDeferredHydrationScript(deferredProps.records));
6657
6656
  const rendererHydrationScript = farmScripts(
6658
- _optionalChain([this, 'access', _257 => _257.rendererRuntime, 'access', _258 => _258.generateHydrationScript, 'optionalCall', _259 => _259()]) || ""
6657
+ _optionalChain([this, 'access', _268 => _268.rendererRuntime, 'access', _269 => _269.generateHydrationScript, 'optionalCall', _270 => _270()]) || ""
6659
6658
  );
6660
6659
  const viteClientScript = farmScripts(`<script type="module" src="/@vite/client"></script>`);
6661
6660
  const farmClientScript = farmScripts(
@@ -6665,7 +6664,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6665
6664
  element,
6666
6665
  {
6667
6666
  rejectLateNavigation: _chunkD4ROBNTKcjs._isFarmMarkdownPageCheck.call(void 0,
6668
- _optionalChain([req, 'access', _260 => _260.headers, 'optionalAccess', _261 => _261[_chunkD4ROBNTKcjs.FARM_MARKDOWN_PAGE_CHECK_HEADER]])
6667
+ _optionalChain([req, 'access', _271 => _271.headers, 'optionalAccess', _272 => _272[_chunkD4ROBNTKcjs.FARM_MARKDOWN_PAGE_CHECK_HEADER]])
6669
6668
  )
6670
6669
  }
6671
6670
  );
@@ -6677,7 +6676,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6677
6676
  viewport: viewportTags
6678
6677
  } = _chunkLZESP4IRcjs.renderMetadataHead.call(void 0, req.__FARM_METADATA__, {
6679
6678
  pathname: getFarmMetadataPathname(req),
6680
- jsonLd: _optionalChain([this, 'access', _262 => _262.config, 'access', _263 => _263.agent, 'optionalAccess', _264 => _264.jsonLd])
6679
+ jsonLd: _optionalChain([this, 'access', _273 => _273.config, 'access', _274 => _274.agent, 'optionalAccess', _275 => _275.jsonLd])
6681
6680
  });
6682
6681
  const documentTitleTag = !hasExplicitTitle && /<title[\s>]/i.test(rendererHead) ? "" : `<title>${title}</title>`;
6683
6682
  const rendererHasTitle = /<title[\s>]/i.test(rendererHead);
@@ -6687,19 +6686,19 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6687
6686
  i18nSnapshot,
6688
6687
  this.getI18nAlternateOptions(req, req.__FARM_METADATA__)
6689
6688
  ) : "";
6690
- const themeDocument = _chunk7YHSD3Z6cjs.createFarmThemeDocumentParts.call(void 0,
6689
+ const themeDocument = _chunkGVNCWSQVcjs.createFarmThemeDocumentParts.call(void 0,
6691
6690
  this.config.theme,
6692
6691
  this.config.basePath,
6693
6692
  _chunk2FUIT2G2cjs.getTheme.call(void 0, )
6694
6693
  );
6695
6694
  themeDocument.head = farmScripts(themeDocument.head);
6696
- const fullDocument = _chunk7YHSD3Z6cjs.extractFarmFullDocument.call(void 0, content);
6695
+ const fullDocument = _chunkGVNCWSQVcjs.extractFarmFullDocument.call(void 0, content);
6697
6696
  let html;
6698
6697
  if (fullDocument) {
6699
6698
  const shouldReplaceLayoutTitle = hasExplicitTitle || rendererHasTitle;
6700
- const documentHtml = shouldReplaceLayoutTitle ? _chunk7YHSD3Z6cjs.removeFarmDocumentTitles.call(void 0, fullDocument) : fullDocument;
6701
- const effectiveRendererHead = hasExplicitTitle ? _chunk7YHSD3Z6cjs.removeFarmDocumentTitles.call(void 0, rendererHead) : rendererHead;
6702
- html = _chunk7YHSD3Z6cjs.composeFarmFullDocument.call(void 0, documentHtml, {
6699
+ const documentHtml = shouldReplaceLayoutTitle ? _chunkGVNCWSQVcjs.removeFarmDocumentTitles.call(void 0, fullDocument) : fullDocument;
6700
+ const effectiveRendererHead = hasExplicitTitle ? _chunkGVNCWSQVcjs.removeFarmDocumentTitles.call(void 0, rendererHead) : rendererHead;
6701
+ html = _chunkGVNCWSQVcjs.composeFarmFullDocument.call(void 0, documentHtml, {
6703
6702
  fallbackIcon: !hasFavicon,
6704
6703
  viewport: viewportTags,
6705
6704
  htmlAttributes: `${i18nSnapshot ? ` lang="${escapeHtmlAttribute2(i18nSnapshot.locale)}" dir="${escapeHtmlAttribute2(i18nSnapshot.direction)}"` : ""}${themeDocument.attributes}`,
@@ -6725,7 +6724,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6725
6724
  });
6726
6725
  } else {
6727
6726
  html = `<!DOCTYPE html>
6728
- <html lang="${escapeHtmlAttribute2(_optionalChain([i18nSnapshot, 'optionalAccess', _265 => _265.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}${themeDocument.attributes}>
6727
+ <html lang="${escapeHtmlAttribute2(_optionalChain([i18nSnapshot, 'optionalAccess', _276 => _276.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}${themeDocument.attributes}>
6729
6728
  <head>
6730
6729
  ${themeDocument.head}
6731
6730
  <meta charset="utf-8">
@@ -6756,7 +6755,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6756
6755
  const securedHtml = this.secureDocumentHTML(req, html);
6757
6756
  if ((req.method || "GET").toUpperCase() !== "HEAD") res.write(securedHtml);
6758
6757
  res.end();
6759
- if (!options.captureStaticShell) await _optionalChain([options, 'access', _266 => _266.onComplete, 'optionalCall', _267 => _267(securedHtml)]);
6758
+ if (!options.captureStaticShell) await _optionalChain([options, 'access', _277 => _277.onComplete, 'optionalCall', _278 => _278(securedHtml)]);
6760
6759
  _chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, {
6761
6760
  type: "render.stream.complete",
6762
6761
  route,
@@ -6766,7 +6765,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6766
6765
  _chunkGS3WR5HXcjs.emitFarmEvent.call(void 0, { type: "render.error", route, error });
6767
6766
  throw error;
6768
6767
  } finally {
6769
- _optionalChain([clearMiddlewareData, 'optionalCall', _268 => _268()]);
6768
+ _optionalChain([clearMiddlewareData, 'optionalCall', _279 => _279()]);
6770
6769
  }
6771
6770
  }
6772
6771
  /**
@@ -6781,7 +6780,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6781
6780
  if (!rootLayout) return false;
6782
6781
  try {
6783
6782
  const Layout = (await this.routeManager.loadLayoutModule(rootLayout.modulePath)).default;
6784
- if (typeof Layout !== "function" || _optionalChain([Layout, 'access', _269 => _269.prototype, 'optionalAccess', _270 => _270.isReactComponent]) || _optionalChain([Layout, 'access', _271 => _271.constructor, 'optionalAccess', _272 => _272.name]) === "AsyncFunction") {
6783
+ if (typeof Layout !== "function" || _optionalChain([Layout, 'access', _280 => _280.prototype, 'optionalAccess', _281 => _281.isReactComponent]) || _optionalChain([Layout, 'access', _282 => _282.constructor, 'optionalAccess', _283 => _283.name]) === "AsyncFunction") {
6785
6784
  return false;
6786
6785
  }
6787
6786
  const cached = documentLayouts.get(Layout);
@@ -6793,19 +6792,19 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6793
6792
  params: {}
6794
6793
  });
6795
6794
  rendersDocument = this.rendererRuntime.isValidElement(rendered) && rendered.type === "html";
6796
- } catch (e19) {
6795
+ } catch (e18) {
6797
6796
  rendersDocument = false;
6798
6797
  }
6799
6798
  documentLayouts.set(Layout, rendersDocument);
6800
6799
  return rendersDocument;
6801
- } catch (e20) {
6800
+ } catch (e19) {
6802
6801
  return false;
6803
6802
  }
6804
6803
  }
6805
6804
  async renderWithSSR(element, req, res, clearMiddlewareData, options = {}) {
6806
6805
  const renderToPipeableStream = this.rendererRuntime.renderToPipeableStream;
6807
6806
  const fullDocumentRouteKey = options.observabilityRoute || req.__FARM_ROUTE__ || req.url || "/";
6808
- if (!renderToPipeableStream || _chunkD4ROBNTKcjs._isFarmMarkdownPageCheck.call(void 0, _optionalChain([req, 'access', _273 => _273.headers, 'optionalAccess', _274 => _274[_chunkD4ROBNTKcjs.FARM_MARKDOWN_PAGE_CHECK_HEADER]])) || fullDocumentRoutes.has(fullDocumentRouteKey) || await this.rootLayoutRendersDocument()) {
6807
+ if (!renderToPipeableStream || _chunkD4ROBNTKcjs._isFarmMarkdownPageCheck.call(void 0, _optionalChain([req, 'access', _284 => _284.headers, 'optionalAccess', _285 => _285[_chunkD4ROBNTKcjs.FARM_MARKDOWN_PAGE_CHECK_HEADER]])) || fullDocumentRoutes.has(fullDocumentRouteKey) || await this.rootLayoutRendersDocument()) {
6809
6808
  return this.renderBufferedSSR(element, req, res, clearMiddlewareData, options);
6810
6809
  }
6811
6810
  return new Promise((resolve3, reject) => {
@@ -6918,7 +6917,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6918
6917
  viewport: viewportTags
6919
6918
  } = _chunkLZESP4IRcjs.renderMetadataHead.call(void 0, req.__FARM_METADATA__, {
6920
6919
  pathname: getFarmMetadataPathname(req),
6921
- jsonLd: _optionalChain([this, 'access', _275 => _275.config, 'access', _276 => _276.agent, 'optionalAccess', _277 => _277.jsonLd])
6920
+ jsonLd: _optionalChain([this, 'access', _286 => _286.config, 'access', _287 => _287.agent, 'optionalAccess', _288 => _288.jsonLd])
6922
6921
  });
6923
6922
  const i18nSnapshot = _chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0, );
6924
6923
  const i18nAlternateTags = i18nSnapshot ? renderI18nAlternateLinks(
@@ -6927,7 +6926,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6927
6926
  this.getI18nAlternateOptions(req, req.__FARM_METADATA__)
6928
6927
  ) : "";
6929
6928
  const fontHead = renderFarmFontDevHead(this.config.root || process.cwd());
6930
- const themeDocument = _chunk7YHSD3Z6cjs.createFarmThemeDocumentParts.call(void 0,
6929
+ const themeDocument = _chunkGVNCWSQVcjs.createFarmThemeDocumentParts.call(void 0,
6931
6930
  this.config.theme,
6932
6931
  this.config.basePath,
6933
6932
  _chunk2FUIT2G2cjs.getTheme.call(void 0, )
@@ -6943,7 +6942,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6943
6942
  nonce: cspNonce,
6944
6943
  onShellReady() {
6945
6944
  if (pendingNavigationError) {
6946
- _optionalChain([abort, 'optionalCall', _278 => _278(pendingNavigationError)]);
6945
+ _optionalChain([abort, 'optionalCall', _289 => _289(pendingNavigationError)]);
6947
6946
  if (clearMiddlewareData) {
6948
6947
  clearMiddlewareData();
6949
6948
  }
@@ -6961,7 +6960,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6961
6960
  console.log(`[FARM STREAM] onShellReady at ${shellReadyMs}ms`);
6962
6961
  }
6963
6962
  const shell = `<!DOCTYPE html>
6964
- <html lang="${escapeHtmlAttribute2(_optionalChain([i18nSnapshot, 'optionalAccess', _279 => _279.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}${themeDocument.attributes}>
6963
+ <html lang="${escapeHtmlAttribute2(_optionalChain([i18nSnapshot, 'optionalAccess', _290 => _290.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}${themeDocument.attributes}>
6965
6964
  <head>
6966
6965
  ${themeDocument.head}
6967
6966
  <meta charset="utf-8">
@@ -6980,7 +6979,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6980
6979
  <div id="root">`;
6981
6980
  const securedShell = stampDocumentHTML(shell);
6982
6981
  htmlParts.push(securedShell);
6983
- _optionalChain([staticShellParts, 'optionalAccess', _280 => _280.push, 'call', _281 => _281(securedShell)]);
6982
+ _optionalChain([staticShellParts, 'optionalAccess', _291 => _291.push, 'call', _292 => _292(securedShell)]);
6984
6983
  let firstChunk = true;
6985
6984
  let checkedFullDocument = false;
6986
6985
  let documentPrefix = "";
@@ -6990,7 +6989,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
6990
6989
  if (!chunkText) return;
6991
6990
  if (!checkedFullDocument) {
6992
6991
  documentPrefix += chunkText;
6993
- const prefix = _chunk7YHSD3Z6cjs.classifyFarmDocumentPrefix.call(void 0, documentPrefix);
6992
+ const prefix = _chunkGVNCWSQVcjs.classifyFarmDocumentPrefix.call(void 0, documentPrefix);
6994
6993
  if (prefix !== "pending") {
6995
6994
  checkedFullDocument = true;
6996
6995
  documentPrefix = "";
@@ -7007,7 +7006,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7007
7006
  staticShellClosed = true;
7008
7007
  if (!suspenseHoleEmitted) {
7009
7008
  suspenseHoleEmitted = true;
7010
- _optionalChain([options, 'access', _282 => _282.onSuspenseHoleDetected, 'optionalCall', _283 => _283()]);
7009
+ _optionalChain([options, 'access', _293 => _293.onSuspenseHoleDetected, 'optionalCall', _294 => _294()]);
7011
7010
  }
7012
7011
  } else {
7013
7012
  staticShellParts.push(chunkText);
@@ -7164,7 +7163,7 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7164
7163
  return await this.routeManager.loadRouteModule(notFoundPath);
7165
7164
  }
7166
7165
  async loadNotFoundComponent() {
7167
- return await _asyncNullishCoalesce(await _asyncOptionalChain([(await this.loadNotFoundModule()), 'optionalAccess', async _284 => _284.default]), async () => ( null));
7166
+ return await _asyncNullishCoalesce(await _asyncOptionalChain([(await this.loadNotFoundModule()), 'optionalAccess', async _295 => _295.default]), async () => ( null));
7168
7167
  }
7169
7168
  /** The not-found document's head: layout and not-found metadata, as production renders it. */
7170
7169
  async notFoundMetadataHead(layoutModule, notFoundModule) {
@@ -7187,13 +7186,13 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7187
7186
  */
7188
7187
  async createLateNavigationRecoveryHTML(req, error) {
7189
7188
  if (_chunkOX6O6WVAcjs.isFarmRedirectError.call(void 0, error)) {
7190
- return _chunk7YHSD3Z6cjs.createLateRedirectRecovery.call(void 0,
7189
+ return _chunkGVNCWSQVcjs.createLateRedirectRecovery.call(void 0,
7191
7190
  this.localizeRedirectUrl(_chunkOX6O6WVAcjs.getFarmRedirectError.call(void 0, error).url),
7192
7191
  this.getCspNonce(req) || ""
7193
7192
  );
7194
7193
  }
7195
7194
  const pathname = _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, {
7196
- trustProxy: _optionalChain([this, 'access', _285 => _285.config, 'access', _286 => _286.server, 'optionalAccess', _287 => _287.trustProxy])
7195
+ trustProxy: _optionalChain([this, 'access', _296 => _296.config, 'access', _297 => _297.server, 'optionalAccess', _298 => _298.trustProxy])
7197
7196
  }).pathname;
7198
7197
  let content = this.defaultNotFoundContent();
7199
7198
  const NotFoundComponent = await this.loadNotFoundComponent();
@@ -7209,12 +7208,12 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7209
7208
  _chunk5QIKR7RRcjs.logger.warn(`not-found page could not render outside its layout, using Farm's: ${error2}`);
7210
7209
  }
7211
7210
  }
7212
- return _chunk7YHSD3Z6cjs.createLateNotFoundRecovery.call(void 0, content, this.getCspNonce(req) || "");
7211
+ return _chunkGVNCWSQVcjs.createLateNotFoundRecovery.call(void 0, content, this.getCspNonce(req) || "");
7213
7212
  }
7214
7213
  async render404(req, res) {
7215
7214
  res.statusCode = 404;
7216
7215
  const pathname = _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, {
7217
- trustProxy: _optionalChain([this, 'access', _288 => _288.config, 'access', _289 => _289.server, 'optionalAccess', _290 => _290.trustProxy])
7216
+ trustProxy: _optionalChain([this, 'access', _299 => _299.config, 'access', _300 => _300.server, 'optionalAccess', _301 => _301.trustProxy])
7218
7217
  }).pathname;
7219
7218
  const acceptHeader = req.headers.accept;
7220
7219
  const accept = Array.isArray(acceptHeader) ? acceptHeader.join(",") : acceptHeader;
@@ -7242,9 +7241,9 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7242
7241
  );
7243
7242
  if (notFoundPath) {
7244
7243
  const notFoundModule = await this.loadNotFoundModule();
7245
- const NotFoundComponent = _nullishCoalesce(_optionalChain([notFoundModule, 'optionalAccess', _291 => _291.default]), () => ( null));
7244
+ const NotFoundComponent = _nullishCoalesce(_optionalChain([notFoundModule, 'optionalAccess', _302 => _302.default]), () => ( null));
7246
7245
  if (NotFoundComponent) {
7247
- const LayoutComponent = _nullishCoalesce(_optionalChain([layoutModule, 'optionalAccess', _292 => _292.default]), () => ( null));
7246
+ const LayoutComponent = _nullishCoalesce(_optionalChain([layoutModule, 'optionalAccess', _303 => _303.default]), () => ( null));
7248
7247
  let element = this.rendererRuntime.createElement(NotFoundComponent, { pathname });
7249
7248
  if (LayoutComponent) {
7250
7249
  element = this.rendererRuntime.createElement(LayoutComponent, {
@@ -7284,23 +7283,23 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7284
7283
  res.statusCode = statusCode;
7285
7284
  const isDev = process.env.NODE_ENV === "development";
7286
7285
  const requestUrl = _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, {
7287
- trustProxy: _optionalChain([this, 'access', _293 => _293.config, 'access', _294 => _294.server, 'optionalAccess', _295 => _295.trustProxy])
7286
+ trustProxy: _optionalChain([this, 'access', _304 => _304.config, 'access', _305 => _305.server, 'optionalAccess', _306 => _306.trustProxy])
7288
7287
  });
7289
7288
  const diagnostics = isDev ? createDefaultErrorDiagnostics(error, this.config.root || process.cwd()) : void 0;
7290
- const statusText = _chunk7YHSD3Z6cjs.getDefaultErrorStatusText.call(void 0, statusCode);
7289
+ const statusText = _chunkGVNCWSQVcjs.getDefaultErrorStatusText.call(void 0, statusCode);
7291
7290
  const content = this.stampFarmScripts(
7292
7291
  req,
7293
- _chunk7YHSD3Z6cjs.createDefaultErrorMarkup.call(void 0, {
7292
+ _chunkGVNCWSQVcjs.createDefaultErrorMarkup.call(void 0, {
7294
7293
  statusCode,
7295
7294
  statusText,
7296
7295
  requestPath: requestUrl.pathname,
7297
7296
  method: req.method || "GET",
7298
- message: _optionalChain([diagnostics, 'optionalAccess', _296 => _296.message]),
7299
- errorName: _optionalChain([diagnostics, 'optionalAccess', _297 => _297.name]),
7300
- stack: _optionalChain([diagnostics, 'optionalAccess', _298 => _298.stack]),
7301
- sourceFrame: _optionalChain([diagnostics, 'optionalAccess', _299 => _299.sourceFrame]),
7297
+ message: _optionalChain([diagnostics, 'optionalAccess', _307 => _307.message]),
7298
+ errorName: _optionalChain([diagnostics, 'optionalAccess', _308 => _308.name]),
7299
+ stack: _optionalChain([diagnostics, 'optionalAccess', _309 => _309.stack]),
7300
+ sourceFrame: _optionalChain([diagnostics, 'optionalAccess', _310 => _310.sourceFrame]),
7302
7301
  development: isDev,
7303
- farmVersion: _chunkAHFRQMRXcjs.FARM_VERSION,
7302
+ farmVersion: _chunkYBDSTNMHcjs.FARM_VERSION,
7304
7303
  nodeVersion: process.version,
7305
7304
  mode: isDev ? "development" : "production"
7306
7305
  })
@@ -7326,8 +7325,8 @@ window.__FARM_I18N__ = ${_chunkXJXBIP67cjs.getFarmI18nClientSnapshot.call(void 0
7326
7325
  */
7327
7326
  getI18nAlternateOptions(req, metadata) {
7328
7327
  return {
7329
- metadataBase: _optionalChain([metadata, 'optionalAccess', _300 => _300.metadataBase]),
7330
- origin: req ? _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, { trustProxy: _optionalChain([this, 'access', _301 => _301.config, 'access', _302 => _302.server, 'optionalAccess', _303 => _303.trustProxy]) }).origin : void 0
7328
+ metadataBase: _optionalChain([metadata, 'optionalAccess', _311 => _311.metadataBase]),
7329
+ origin: req ? _chunkZTP3BJG6cjs.resolveFarmRequestURL.call(void 0, req, { trustProxy: _optionalChain([this, 'access', _312 => _312.config, 'access', _313 => _313.server, 'optionalAccess', _314 => _314.trustProxy]) }).origin : void 0
7331
7330
  };
7332
7331
  }
7333
7332
  createFullHTML(content, isClientComponent = false, requestPath = "/", metadataHead, alternates = {}) {
@@ -7346,20 +7345,20 @@ ${i18nSnapshot ? `window.__FARM_I18N__ = ${serializeInlineValue(i18nSnapshot)};`
7346
7345
  this.getI18nAlternateOptions(alternates.req, alternates.metadata)
7347
7346
  ) : "";
7348
7347
  const fontHead = renderFarmFontDevHead(this.config.root || process.cwd());
7349
- const themeDocument = _chunk7YHSD3Z6cjs.createFarmThemeDocumentParts.call(void 0,
7348
+ const themeDocument = _chunkGVNCWSQVcjs.createFarmThemeDocumentParts.call(void 0,
7350
7349
  this.config.theme,
7351
7350
  this.config.basePath,
7352
7351
  _chunk2FUIT2G2cjs.getTheme.call(void 0, )
7353
7352
  );
7354
7353
  themeDocument.head = farmScripts(themeDocument.head);
7355
7354
  const rendererHydrationScript = farmScripts(
7356
- _optionalChain([this, 'access', _304 => _304.rendererRuntime, 'access', _305 => _305.generateHydrationScript, 'optionalCall', _306 => _306()]) || ""
7355
+ _optionalChain([this, 'access', _315 => _315.rendererRuntime, 'access', _316 => _316.generateHydrationScript, 'optionalCall', _317 => _317()]) || ""
7357
7356
  );
7358
- const viewportTags = _chunkLZESP4IRcjs.renderViewportHead.call(void 0, _optionalChain([alternates, 'access', _307 => _307.metadata, 'optionalAccess', _308 => _308.viewport]));
7359
- const fullDocument = _chunk7YHSD3Z6cjs.extractFarmFullDocument.call(void 0, content);
7357
+ const viewportTags = _chunkLZESP4IRcjs.renderViewportHead.call(void 0, _optionalChain([alternates, 'access', _318 => _318.metadata, 'optionalAccess', _319 => _319.viewport]));
7358
+ const fullDocument = _chunkGVNCWSQVcjs.extractFarmFullDocument.call(void 0, content);
7360
7359
  if (fullDocument) {
7361
- return _chunk7YHSD3Z6cjs.composeFarmFullDocument.call(void 0,
7362
- metadataHead ? _chunk7YHSD3Z6cjs.removeFarmDocumentTitles.call(void 0, fullDocument) : fullDocument,
7360
+ return _chunkGVNCWSQVcjs.composeFarmFullDocument.call(void 0,
7361
+ metadataHead ? _chunkGVNCWSQVcjs.removeFarmDocumentTitles.call(void 0, fullDocument) : fullDocument,
7363
7362
  {
7364
7363
  fallbackIcon: !metadataHead,
7365
7364
  viewport: viewportTags,
@@ -7385,7 +7384,7 @@ ${i18nSnapshot ? `window.__FARM_I18N__ = ${serializeInlineValue(i18nSnapshot)};`
7385
7384
  );
7386
7385
  }
7387
7386
  return `<!DOCTYPE html>
7388
- <html lang="${escapeHtmlAttribute2(_optionalChain([i18nSnapshot, 'optionalAccess', _309 => _309.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}${themeDocument.attributes}>
7387
+ <html lang="${escapeHtmlAttribute2(_optionalChain([i18nSnapshot, 'optionalAccess', _320 => _320.locale]) || "en")}"${i18nSnapshot ? ` dir="${i18nSnapshot.direction}"` : ""}${themeDocument.attributes}>
7389
7388
  <head>
7390
7389
  ${themeDocument.head}
7391
7390
  <meta charset="utf-8">
@@ -7427,7 +7426,7 @@ ${clientScript}
7427
7426
  res.setHeader(_chunkC5GUTBZKcjs.FARM_DEPLOYMENT_ID_HEADER, deploymentId);
7428
7427
  if ((req.method || "GET").toUpperCase() !== "GET") return;
7429
7428
  const forwardedProto = req.headers["x-forwarded-proto"];
7430
- const isSecure = _optionalChain([(Array.isArray(forwardedProto) ? forwardedProto[0] : forwardedProto), 'optionalAccess', _310 => _310.split, 'call', _311 => _311(","), 'access', _312 => _312[0], 'optionalAccess', _313 => _313.trim, 'call', _314 => _314()]) === "https" || Boolean(_optionalChain([req, 'access', _315 => _315.socket, 'optionalAccess', _316 => _316.encrypted]));
7429
+ const isSecure = _optionalChain([(Array.isArray(forwardedProto) ? forwardedProto[0] : forwardedProto), 'optionalAccess', _321 => _321.split, 'call', _322 => _322(","), 'access', _323 => _323[0], 'optionalAccess', _324 => _324.trim, 'call', _325 => _325()]) === "https" || Boolean(_optionalChain([req, 'access', _326 => _326.socket, 'optionalAccess', _327 => _327.encrypted]));
7431
7430
  const cookie = _chunkC5GUTBZKcjs.createFarmDeploymentCookie.call(void 0, deploymentId, this.config.basePath || "/", isSecure);
7432
7431
  const existing = res.getHeader("Set-Cookie");
7433
7432
  if (Array.isArray(existing)) {
@@ -7516,7 +7515,7 @@ var _FarmApp = class _FarmApp {
7516
7515
  storage: config.storage || {},
7517
7516
  schema: config.schema || {},
7518
7517
  cache: config.cache || {},
7519
- auth: isResolvedAuthConfig(config.auth) ? config.auth : _chunkJR4QCLJYcjs.resolveFarmAuthConfig.call(void 0, config.auth),
7518
+ auth: isResolvedAuthConfig(config.auth) ? config.auth : _chunkPDU4P2ICcjs.resolveFarmAuthConfig.call(void 0, config.auth),
7520
7519
  integrations: config.integrations || {},
7521
7520
  plugins: config.plugins || [],
7522
7521
  migrations: config.migrations || { commands: [] },
@@ -7551,17 +7550,17 @@ var _FarmApp = class _FarmApp {
7551
7550
  config.devtools,
7552
7551
  process.env.NODE_ENV === "production" ? "production" : "development"
7553
7552
  ),
7554
- devIndicators: _chunkJR4QCLJYcjs.resolveFarmDevIndicatorsConfig.call(void 0,
7553
+ devIndicators: _chunkPDU4P2ICcjs.resolveFarmDevIndicatorsConfig.call(void 0,
7555
7554
  config.devIndicators,
7556
7555
  process.env.NODE_ENV === "production" ? "production" : "development"
7557
7556
  ),
7558
7557
  env: config.env || { server: {}, public: {} },
7559
7558
  suppressLintOnLink: _nullishCoalesce(config.suppressLintOnLink, () => ( false)),
7560
7559
  experimental: {
7561
- serverComponents: _nullishCoalesce(_optionalChain([config, 'access', _317 => _317.experimental, 'optionalAccess', _318 => _318.serverComponents]), () => ( false)),
7562
- serverActions: _nullishCoalesce(_optionalChain([config, 'access', _319 => _319.experimental, 'optionalAccess', _320 => _320.serverActions]), () => ( false)),
7563
- isolatedClientHydration: _nullishCoalesce(_optionalChain([config, 'access', _321 => _321.experimental, 'optionalAccess', _322 => _322.isolatedClientHydration]), () => ( "off")),
7564
- ppr: _nullishCoalesce(_optionalChain([config, 'access', _323 => _323.experimental, 'optionalAccess', _324 => _324.ppr]), () => ( false)),
7560
+ serverComponents: _nullishCoalesce(_optionalChain([config, 'access', _328 => _328.experimental, 'optionalAccess', _329 => _329.serverComponents]), () => ( false)),
7561
+ serverActions: _nullishCoalesce(_optionalChain([config, 'access', _330 => _330.experimental, 'optionalAccess', _331 => _331.serverActions]), () => ( false)),
7562
+ isolatedClientHydration: _nullishCoalesce(_optionalChain([config, 'access', _332 => _332.experimental, 'optionalAccess', _333 => _333.isolatedClientHydration]), () => ( "off")),
7563
+ ppr: _nullishCoalesce(_optionalChain([config, 'access', _334 => _334.experimental, 'optionalAccess', _335 => _335.ppr]), () => ( false)),
7565
7564
  ...config.experimental
7566
7565
  },
7567
7566
  agent: _nullishCoalesce(config.agent, () => ( {})),
@@ -7612,7 +7611,7 @@ function isResolvedAuthConfig(value) {
7612
7611
  }
7613
7612
  _chunkS3JO3N4Hcjs.__name.call(void 0, isResolvedAuthConfig, "isResolvedAuthConfig");
7614
7613
  function normalizeFarmAppAPIConfig(config) {
7615
- if (typeof _optionalChain([config, 'optionalAccess', _325 => _325.baseURL]) === "function" || typeof _optionalChain([config, 'optionalAccess', _326 => _326.basePath]) === "function") {
7614
+ if (typeof _optionalChain([config, 'optionalAccess', _336 => _336.baseURL]) === "function" || typeof _optionalChain([config, 'optionalAccess', _337 => _337.basePath]) === "function") {
7616
7615
  throw new Error(
7617
7616
  "Farm API config resolver functions must be processed with resolveConfig() before creating a FarmApp."
7618
7617
  );
@@ -7629,7 +7628,7 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, createFarmApp, "createFarmApp");
7629
7628
  var SHARP_INSTALL_HINT = _chunkLYLEZIG3cjs.formatOptionalPeerInstallHint.call(void 0, "sharp", "optimize images");
7630
7629
  var CLOUDFLARE_IMAGE_PRESETS = /* @__PURE__ */ new Set(["cloudflare", "cloudflare-pages", "cloudflare-module"]);
7631
7630
  function resolveFarmImageProviderForRuntime(images, options) {
7632
- const provider = _nullishCoalesce(_optionalChain([images, 'optionalAccess', _327 => _327.provider]), () => ( "auto"));
7631
+ const provider = _nullishCoalesce(_optionalChain([images, 'optionalAccess', _338 => _338.provider]), () => ( "auto"));
7633
7632
  if (provider === "none") return images;
7634
7633
  const usesSharp = options.dev ? true : provider === "node" || provider === "auto" && !CLOUDFLARE_IMAGE_PRESETS.has(options.preset || "");
7635
7634
  if (!usesSharp || _chunkLYLEZIG3cjs.isOptionalPeerInstalled.call(void 0, options.root, "sharp")) return images;
@@ -7666,7 +7665,7 @@ function resolveFarmAppPackages(root) {
7666
7665
  let manifest;
7667
7666
  try {
7668
7667
  manifest = JSON.parse(fs2.default.readFileSync(path4.default.join(root, "package.json"), "utf8"));
7669
- } catch (e21) {
7668
+ } catch (e20) {
7670
7669
  return {};
7671
7670
  }
7672
7671
  const names = new Set(
@@ -7685,7 +7684,7 @@ function resolveFarmAppPackages(root) {
7685
7684
  if (typeof version === "string" && /^[0-9A-Za-z.+-]{1,64}$/.test(version))
7686
7685
  versions[name] = version;
7687
7686
  break;
7688
- } catch (e22) {
7687
+ } catch (e21) {
7689
7688
  const parent = path4.default.dirname(dir);
7690
7689
  if (parent === dir) break;
7691
7690
  dir = parent;
@@ -7762,9 +7761,9 @@ function staticValue(node) {
7762
7761
  }
7763
7762
  _chunkS3JO3N4Hcjs.__name.call(void 0, staticValue, "staticValue");
7764
7763
  function property(object, name) {
7765
- return _optionalChain([object, 'access', _328 => _328.properties, 'access', _329 => _329.find, 'call', _330 => _330(
7764
+ return _optionalChain([object, 'access', _339 => _339.properties, 'access', _340 => _340.find, 'call', _341 => _341(
7766
7765
  (entry) => entry.type === "Property" && !entry.computed && (entry.key.name === name || entry.key.value === name)
7767
- ), 'optionalAccess', _331 => _331.value]);
7766
+ ), 'optionalAccess', _342 => _342.value]);
7768
7767
  }
7769
7768
  _chunkS3JO3N4Hcjs.__name.call(void 0, property, "property");
7770
7769
  function toolFromObject(object) {
@@ -7804,7 +7803,7 @@ function findFarmWebMCPTools(code, filename = "module.tsx") {
7804
7803
  let program;
7805
7804
  try {
7806
7805
  program = parseAst(code, { lang });
7807
- } catch (e23) {
7806
+ } catch (e22) {
7808
7807
  return [];
7809
7808
  }
7810
7809
  const locals = /* @__PURE__ */ new Map();
@@ -7812,7 +7811,7 @@ function findFarmWebMCPTools(code, filename = "module.tsx") {
7812
7811
  if (statement.type !== "ImportDeclaration" || statement.source.value !== WEBMCP_CLIENT)
7813
7812
  continue;
7814
7813
  for (const specifier of statement.specifiers) {
7815
- const imported = _nullishCoalesce(_optionalChain([specifier, 'access', _332 => _332.imported, 'optionalAccess', _333 => _333.name]), () => ( _optionalChain([specifier, 'access', _334 => _334.imported, 'optionalAccess', _335 => _335.value])));
7814
+ const imported = _nullishCoalesce(_optionalChain([specifier, 'access', _343 => _343.imported, 'optionalAccess', _344 => _344.name]), () => ( _optionalChain([specifier, 'access', _345 => _345.imported, 'optionalAccess', _346 => _346.value])));
7816
7815
  if (specifier.type === "ImportSpecifier" && DEFINERS.has(imported))
7817
7816
  locals.set(specifier.local.name, imported);
7818
7817
  }
@@ -7828,7 +7827,7 @@ function findFarmWebMCPTools(code, filename = "module.tsx") {
7828
7827
  const [argument] = current.arguments;
7829
7828
  if (definer && argument) {
7830
7829
  const objects = definer === "registerWebMCPTools" ? argument.type === "ArrayExpression" ? argument.elements.filter(
7831
- (element) => _optionalChain([element, 'optionalAccess', _336 => _336.type]) === "ObjectExpression"
7830
+ (element) => _optionalChain([element, 'optionalAccess', _347 => _347.type]) === "ObjectExpression"
7832
7831
  ) : [] : argument.type === "ObjectExpression" ? [argument] : [];
7833
7832
  for (const object of objects) {
7834
7833
  const tool = toolFromObject(object);
@@ -7853,7 +7852,7 @@ function collectFarmWebMCPTools(root, srcDir = "src") {
7853
7852
  absolute: true,
7854
7853
  ignore: ["**/node_modules/**", "**/*.d.ts", "**/*.{test,spec}.*", "**/__tests__/**"]
7855
7854
  });
7856
- } catch (e24) {
7855
+ } catch (e23) {
7857
7856
  return [];
7858
7857
  }
7859
7858
  const seen = /* @__PURE__ */ new Set();
@@ -7862,7 +7861,7 @@ function collectFarmWebMCPTools(root, srcDir = "src") {
7862
7861
  let mtimeMs;
7863
7862
  try {
7864
7863
  mtimeMs = fs2.default.statSync(file).mtimeMs;
7865
- } catch (e25) {
7864
+ } catch (e24) {
7866
7865
  continue;
7867
7866
  }
7868
7867
  let entry = cache.get(file);
@@ -7870,7 +7869,7 @@ function collectFarmWebMCPTools(root, srcDir = "src") {
7870
7869
  let code = "";
7871
7870
  try {
7872
7871
  code = fs2.default.readFileSync(file, "utf8");
7873
- } catch (e26) {
7872
+ } catch (e25) {
7874
7873
  }
7875
7874
  entry = { mtimeMs, tools: findFarmWebMCPTools(code, file) };
7876
7875
  cache.set(file, entry);
@@ -7910,7 +7909,7 @@ function resolveFarmAppClientEntry(root = process.cwd(), srcDir = "src") {
7910
7909
  }
7911
7910
  _chunkS3JO3N4Hcjs.__name.call(void 0, resolveFarmAppClientEntry, "resolveFarmAppClientEntry");
7912
7911
  function resolveFarmClientPlugins(plugins, _root) {
7913
- if (!_optionalChain([plugins, 'optionalAccess', _337 => _337.length])) return [];
7912
+ if (!_optionalChain([plugins, 'optionalAccess', _348 => _348.length])) return [];
7914
7913
  return plugins.flatMap((plugin) => {
7915
7914
  if (!plugin.client) return [];
7916
7915
  assertClientLifecycle(plugin.client, plugin.name);
@@ -7990,7 +7989,7 @@ function assertLifecycleObject(value, pluginName, location, allowedKeys) {
7990
7989
  throw new TypeError(`Client plugin "${pluginName}" has an unknown ${location}.${key} option`);
7991
7990
  }
7992
7991
  const descriptor = Object.getOwnPropertyDescriptor(value, key);
7993
- if (!_optionalChain([descriptor, 'optionalAccess', _338 => _338.enumerable])) {
7992
+ if (!_optionalChain([descriptor, 'optionalAccess', _349 => _349.enumerable])) {
7994
7993
  throw new TypeError(`Client plugin "${pluginName}" ${location}.${key} must be enumerable`);
7995
7994
  }
7996
7995
  if (!("value" in descriptor)) {
@@ -8114,7 +8113,7 @@ function assertPublicData(value, pluginName) {
8114
8113
  throwPublicDataError(pluginName, pathSegments, "cannot contain symbol keys");
8115
8114
  }
8116
8115
  const descriptor = Object.getOwnPropertyDescriptor(current, key);
8117
- if (!_optionalChain([descriptor, 'optionalAccess', _339 => _339.enumerable])) {
8116
+ if (!_optionalChain([descriptor, 'optionalAccess', _350 => _350.enumerable])) {
8118
8117
  throwPublicDataError(
8119
8118
  pluginName,
8120
8119
  [...pathSegments, key],
@@ -8160,8 +8159,8 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, isArrayIndex, "isArrayIndex");
8160
8159
 
8161
8160
  var ADAPTER_EXTENSIONS = ["ts", "tsx", "js", "jsx", "mts", "mjs"];
8162
8161
  function resolveFarmClientCacheAdapterEntry(root, cache2) {
8163
- const client = _optionalChain([cache2, 'optionalAccess', _340 => _340.client]);
8164
- const adapter = _optionalChain([client, 'optionalAccess', _341 => _341.adapter]);
8162
+ const client = _optionalChain([cache2, 'optionalAccess', _351 => _351.client]);
8163
+ const adapter = _optionalChain([client, 'optionalAccess', _352 => _352.adapter]);
8165
8164
  if (adapter === void 0) return void 0;
8166
8165
  if (typeof adapter !== "string" || adapter.trim().length === 0) {
8167
8166
  throw new Error(
@@ -8176,8 +8175,8 @@ function resolveFarmClientCacheAdapterEntry(root, cache2) {
8176
8175
  );
8177
8176
  }
8178
8177
  const options = {};
8179
- if (_optionalChain([client, 'optionalAccess', _342 => _342.version]) !== void 0) options.version = client.version;
8180
- if (_optionalChain([client, 'optionalAccess', _343 => _343.flushDelayMs]) !== void 0) options.flushDelayMs = client.flushDelayMs;
8178
+ if (_optionalChain([client, 'optionalAccess', _353 => _353.version]) !== void 0) options.version = client.version;
8179
+ if (_optionalChain([client, 'optionalAccess', _354 => _354.flushDelayMs]) !== void 0) options.flushDelayMs = client.flushDelayMs;
8181
8180
  return { importPath: found.replace(/\\/g, "/"), options };
8182
8181
  }
8183
8182
  _chunkS3JO3N4Hcjs.__name.call(void 0, resolveFarmClientCacheAdapterEntry, "resolveFarmClientCacheAdapterEntry");
@@ -8317,7 +8316,7 @@ function redactFarmDocsClientConfig(code, filename) {
8317
8316
  const current = node;
8318
8317
  if (current.type === "Property") {
8319
8318
  const name = propertyKeyName(current);
8320
- const valueType = _optionalChain([current, 'access', _344 => _344.value, 'optionalAccess', _345 => _345.type]);
8319
+ const valueType = _optionalChain([current, 'access', _355 => _355.value, 'optionalAccess', _356 => _356.type]);
8321
8320
  const credential = name !== void 0 && (name.toLowerCase() === "headers" || _chunkCY2ZQ5C6cjs.isSecretDocsConfigKey.call(void 0, name) && valueType !== "ObjectExpression" && valueType !== "ArrayExpression");
8322
8321
  if (name && credential) {
8323
8322
  edits.push(
@@ -8349,7 +8348,7 @@ function isFarmDocsClientConfigModule(id, configModule) {
8349
8348
  if (file === configModule) return true;
8350
8349
  try {
8351
8350
  return file === _fs.realpathSync.call(void 0, configModule).replace(/\\/g, "/");
8352
- } catch (e27) {
8351
+ } catch (e26) {
8353
8352
  return false;
8354
8353
  }
8355
8354
  }
@@ -8359,7 +8358,7 @@ function farmDocsClientConfigPlugin(configModule) {
8359
8358
  name: "farm:docs-client-config",
8360
8359
  enforce: "pre",
8361
8360
  transform(code, id, options) {
8362
- if (_optionalChain([options, 'optionalAccess', _346 => _346.ssr]) || !isFarmDocsClientConfigModule(id, configModule)) return null;
8361
+ if (_optionalChain([options, 'optionalAccess', _357 => _357.ssr]) || !isFarmDocsClientConfigModule(id, configModule)) return null;
8363
8362
  const redacted = redactFarmDocsClientConfig(code, id.split("?")[0]);
8364
8363
  return redacted === null ? null : { code: redacted, map: null };
8365
8364
  }
@@ -8367,101 +8366,6 @@ function farmDocsClientConfigPlugin(configModule) {
8367
8366
  }
8368
8367
  _chunkS3JO3N4Hcjs.__name.call(void 0, farmDocsClientConfigPlugin, "farmDocsClientConfigPlugin");
8369
8368
 
8370
- // src/build/tailwind.ts
8371
-
8372
-
8373
- // src/build/vite-plugin-compat.ts
8374
- function adaptTailwindVitePlugin(pluginOption, builder) {
8375
- if (builder !== "rolldown") return pluginOption;
8376
- return adaptPluginOption(pluginOption);
8377
- }
8378
- _chunkS3JO3N4Hcjs.__name.call(void 0, adaptTailwindVitePlugin, "adaptTailwindVitePlugin");
8379
- function adaptPluginOption(pluginOption) {
8380
- if (Array.isArray(pluginOption)) return pluginOption.map(adaptPluginOption);
8381
- if (!pluginOption || typeof pluginOption !== "object") return pluginOption;
8382
- const plugin = pluginOption;
8383
- if (!_optionalChain([plugin, 'access', _347 => _347.name, 'optionalAccess', _348 => _348.startsWith, 'call', _349 => _349("@tailwindcss/vite:generate:")])) return pluginOption;
8384
- if (isVitePluginHook(plugin.transform)) {
8385
- return {
8386
- ...plugin,
8387
- transform: withVite5TransformContext(plugin.transform)
8388
- };
8389
- }
8390
- if (plugin.transform && typeof plugin.transform === "object" && "handler" in plugin.transform && isVitePluginHook(plugin.transform.handler)) {
8391
- return {
8392
- ...plugin,
8393
- transform: {
8394
- ...plugin.transform,
8395
- handler: withVite5TransformContext(plugin.transform.handler)
8396
- }
8397
- };
8398
- }
8399
- return pluginOption;
8400
- }
8401
- _chunkS3JO3N4Hcjs.__name.call(void 0, adaptPluginOption, "adaptPluginOption");
8402
- function isVitePluginHook(value) {
8403
- return typeof value === "function";
8404
- }
8405
- _chunkS3JO3N4Hcjs.__name.call(void 0, isVitePluginHook, "isVitePluginHook");
8406
- function withVite5TransformContext(handler) {
8407
- return function(...args) {
8408
- const context = new Proxy(this, {
8409
- get(target, property2, receiver) {
8410
- if (property2 === "environment") return void 0;
8411
- return Reflect.get(target, property2, receiver);
8412
- }
8413
- });
8414
- return handler.apply(context, args);
8415
- };
8416
- }
8417
- _chunkS3JO3N4Hcjs.__name.call(void 0, withVite5TransformContext, "withVite5TransformContext");
8418
-
8419
- // src/build/tailwind.ts
8420
- var TAILWIND_CSS_IMPORT = /@import\s+["']tailwindcss["']/;
8421
- var TAILWIND_VITE_INSTALL_HINT = _chunkLYLEZIG3cjs.formatOptionalPeerInstallHint.call(void 0,
8422
- "@tailwindcss/vite",
8423
- "enable built-in Tailwind CSS support",
8424
- { dev: true }
8425
- );
8426
- var warnedMissingTailwind = false;
8427
- async function loadTailwindVitePlugin(options = {}, importTailwind = () => import("@tailwindcss/vite")) {
8428
- try {
8429
- const tailwindVite = (await importTailwind()).default;
8430
- const plugin = options.builder ? adaptTailwindVitePlugin(tailwindVite(), options.builder) : tailwindVite();
8431
- if (options.announce) _chunk5QIKR7RRcjs.logger.info("\u{1F4E6} Enabled built-in Tailwind support (@tailwindcss/vite)");
8432
- return plugin;
8433
- } catch (error) {
8434
- if (_chunkLYLEZIG3cjs.isMissingPackageError.call(void 0, error, "@tailwindcss/vite")) return createMissingTailwindPlugin();
8435
- _chunk5QIKR7RRcjs.logger.warn(
8436
- `Tailwind plugin auto-enable failed${options.label ? ` ${options.label}` : ""}; continuing without it: ${error.message}`
8437
- );
8438
- return void 0;
8439
- }
8440
- }
8441
- _chunkS3JO3N4Hcjs.__name.call(void 0, loadTailwindVitePlugin, "loadTailwindVitePlugin");
8442
- function createMissingTailwindPlugin() {
8443
- let root = process.cwd();
8444
- return {
8445
- name: "farm:tailwind-missing",
8446
- enforce: "pre",
8447
- configResolved(config) {
8448
- root = config.root;
8449
- },
8450
- transform(code, id) {
8451
- if (warnedMissingTailwind || !/\.css(?:\?.*)?$/.test(id) || !TAILWIND_CSS_IMPORT.test(code)) {
8452
- return null;
8453
- }
8454
- warnedMissingTailwind = true;
8455
- const file = path4.default.relative(root, id.split("?", 1)[0]).replace(/\\/g, "/");
8456
- _chunk5QIKR7RRcjs.logger.warn(
8457
- `${file} imports Tailwind CSS, but @tailwindcss/vite is not installed; continuing without Tailwind. ${TAILWIND_VITE_INSTALL_HINT}`
8458
- );
8459
- return null;
8460
- }
8461
- };
8462
- }
8463
- _chunkS3JO3N4Hcjs.__name.call(void 0, createMissingTailwindPlugin, "createMissingTailwindPlugin");
8464
-
8465
8369
  // src/server/vite-config.ts
8466
8370
 
8467
8371
  var FARM_CLIENT_ENTRY_PATTERN = "**/{page,layout,loading,error,not-found,default}.{js,jsx,ts,tsx}";
@@ -8478,11 +8382,15 @@ var FARM_CLIENT_OPTIMIZE_DEPS_INCLUDE = [
8478
8382
  "@farm.js/core/i18n/client",
8479
8383
  "@farm.js/core/query/client",
8480
8384
  "@farm.js/core/server-fn/client",
8481
- "@farm.js/core/server-query/client"
8385
+ "@farm.js/core/server-query/client",
8386
+ // Islands mode's browser runtime: Farm imports islx, which the app reaches only through Farm.
8387
+ "@farm.js/core > @farm.js/islx/client",
8388
+ "@farm.js/core > @farm.js/islx/react",
8389
+ "@farm.js/core > @farm.js/islx/react/client"
8482
8390
  ];
8483
8391
  function getFarmClientOptimizeDepsInclude(renderer) {
8484
8392
  return Array.from(
8485
- /* @__PURE__ */ new Set([...FARM_CLIENT_OPTIMIZE_DEPS_INCLUDE, ..._optionalChain([renderer, 'optionalAccess', _350 => _350.optimizeDeps]) || []])
8393
+ /* @__PURE__ */ new Set([...FARM_CLIENT_OPTIMIZE_DEPS_INCLUDE, ..._optionalChain([renderer, 'optionalAccess', _358 => _358.optimizeDeps]) || []])
8486
8394
  );
8487
8395
  }
8488
8396
  _chunkS3JO3N4Hcjs.__name.call(void 0, getFarmClientOptimizeDepsInclude, "getFarmClientOptimizeDepsInclude");
@@ -8507,7 +8415,7 @@ function createFarmClientOptimizeDepsConfig(entries, renderer) {
8507
8415
  // Farm's HTML boots through a virtual module and imports route UI lazily.
8508
8416
  // Explicit entries let Vite finish that crawl before a navigation can
8509
8417
  // rotate the optimizer hash underneath a hydrated React runtime.
8510
- ..._optionalChain([entries, 'optionalAccess', _351 => _351.length]) ? { entries: [...entries] } : {}
8418
+ ..._optionalChain([entries, 'optionalAccess', _359 => _359.length]) ? { entries: [...entries] } : {}
8511
8419
  };
8512
8420
  }
8513
8421
  _chunkS3JO3N4Hcjs.__name.call(void 0, createFarmClientOptimizeDepsConfig, "createFarmClientOptimizeDepsConfig");
@@ -8537,8 +8445,8 @@ function mergeAlias(farmValue, userValue) {
8537
8445
  }
8538
8446
  _chunkS3JO3N4Hcjs.__name.call(void 0, mergeAlias, "mergeAlias");
8539
8447
  function mergeFarmViteConfig(farmConfig, userConfig = {}) {
8540
- const noDiscovery = _nullishCoalesce(_optionalChain([userConfig, 'access', _352 => _352.optimizeDeps, 'optionalAccess', _353 => _353.noDiscovery]), () => ( _optionalChain([farmConfig, 'access', _354 => _354.optimizeDeps, 'optionalAccess', _355 => _355.noDiscovery])));
8541
- const holdUntilCrawlEnd = _nullishCoalesce(_optionalChain([userConfig, 'access', _356 => _356.optimizeDeps, 'optionalAccess', _357 => _357.holdUntilCrawlEnd]), () => ( (_optionalChain([userConfig, 'access', _358 => _358.optimizeDeps, 'optionalAccess', _359 => _359.noDiscovery]) === true ? false : _optionalChain([farmConfig, 'access', _360 => _360.optimizeDeps, 'optionalAccess', _361 => _361.holdUntilCrawlEnd]))));
8448
+ const noDiscovery = _nullishCoalesce(_optionalChain([userConfig, 'access', _360 => _360.optimizeDeps, 'optionalAccess', _361 => _361.noDiscovery]), () => ( _optionalChain([farmConfig, 'access', _362 => _362.optimizeDeps, 'optionalAccess', _363 => _363.noDiscovery])));
8449
+ const holdUntilCrawlEnd = _nullishCoalesce(_optionalChain([userConfig, 'access', _364 => _364.optimizeDeps, 'optionalAccess', _365 => _365.holdUntilCrawlEnd]), () => ( (_optionalChain([userConfig, 'access', _366 => _366.optimizeDeps, 'optionalAccess', _367 => _367.noDiscovery]) === true ? false : _optionalChain([farmConfig, 'access', _368 => _368.optimizeDeps, 'optionalAccess', _369 => _369.holdUntilCrawlEnd]))));
8542
8450
  return {
8543
8451
  ...farmConfig,
8544
8452
  ...userConfig,
@@ -8550,9 +8458,9 @@ function mergeFarmViteConfig(farmConfig, userConfig = {}) {
8550
8458
  resolve: {
8551
8459
  ...farmConfig.resolve,
8552
8460
  ...userConfig.resolve,
8553
- alias: mergeAlias(_optionalChain([farmConfig, 'access', _362 => _362.resolve, 'optionalAccess', _363 => _363.alias]), _optionalChain([userConfig, 'access', _364 => _364.resolve, 'optionalAccess', _365 => _365.alias])),
8461
+ alias: mergeAlias(_optionalChain([farmConfig, 'access', _370 => _370.resolve, 'optionalAccess', _371 => _371.alias]), _optionalChain([userConfig, 'access', _372 => _372.resolve, 'optionalAccess', _373 => _373.alias])),
8554
8462
  dedupe: Array.from(
8555
- /* @__PURE__ */ new Set([..._optionalChain([farmConfig, 'access', _366 => _366.resolve, 'optionalAccess', _367 => _367.dedupe]) || [], ..._optionalChain([userConfig, 'access', _368 => _368.resolve, 'optionalAccess', _369 => _369.dedupe]) || []])
8463
+ /* @__PURE__ */ new Set([..._optionalChain([farmConfig, 'access', _374 => _374.resolve, 'optionalAccess', _375 => _375.dedupe]) || [], ..._optionalChain([userConfig, 'access', _376 => _376.resolve, 'optionalAccess', _377 => _377.dedupe]) || []])
8556
8464
  )
8557
8465
  },
8558
8466
  optimizeDeps: {
@@ -8562,21 +8470,21 @@ function mergeFarmViteConfig(farmConfig, userConfig = {}) {
8562
8470
  holdUntilCrawlEnd,
8563
8471
  include: Array.from(
8564
8472
  /* @__PURE__ */ new Set([
8565
- ..._optionalChain([farmConfig, 'access', _370 => _370.optimizeDeps, 'optionalAccess', _371 => _371.include]) || [],
8566
- ..._optionalChain([userConfig, 'access', _372 => _372.optimizeDeps, 'optionalAccess', _373 => _373.include]) || []
8473
+ ..._optionalChain([farmConfig, 'access', _378 => _378.optimizeDeps, 'optionalAccess', _379 => _379.include]) || [],
8474
+ ..._optionalChain([userConfig, 'access', _380 => _380.optimizeDeps, 'optionalAccess', _381 => _381.include]) || []
8567
8475
  ])
8568
8476
  ),
8569
8477
  exclude: Array.from(
8570
8478
  /* @__PURE__ */ new Set([
8571
- ..._optionalChain([farmConfig, 'access', _374 => _374.optimizeDeps, 'optionalAccess', _375 => _375.exclude]) || [],
8572
- ..._optionalChain([userConfig, 'access', _376 => _376.optimizeDeps, 'optionalAccess', _377 => _377.exclude]) || []
8479
+ ..._optionalChain([farmConfig, 'access', _382 => _382.optimizeDeps, 'optionalAccess', _383 => _383.exclude]) || [],
8480
+ ..._optionalChain([userConfig, 'access', _384 => _384.optimizeDeps, 'optionalAccess', _385 => _385.exclude]) || []
8573
8481
  ])
8574
8482
  )
8575
8483
  },
8576
8484
  ssr: {
8577
8485
  ...farmConfig.ssr,
8578
8486
  ...userConfig.ssr,
8579
- noExternal: mergeNoExternal(_optionalChain([farmConfig, 'access', _378 => _378.ssr, 'optionalAccess', _379 => _379.noExternal]), _optionalChain([userConfig, 'access', _380 => _380.ssr, 'optionalAccess', _381 => _381.noExternal]))
8487
+ noExternal: mergeNoExternal(_optionalChain([farmConfig, 'access', _386 => _386.ssr, 'optionalAccess', _387 => _387.noExternal]), _optionalChain([userConfig, 'access', _388 => _388.ssr, 'optionalAccess', _389 => _389.noExternal]))
8580
8488
  }
8581
8489
  };
8582
8490
  }
@@ -8630,7 +8538,7 @@ function mergeFarmProductionViteConfig(farmConfig, userConfig = {}) {
8630
8538
  ...farmConfig.build,
8631
8539
  rollupOptions: {
8632
8540
  ...userBundlerOptions,
8633
- ..._optionalChain([farmConfig, 'access', _382 => _382.build, 'optionalAccess', _383 => _383.rollupOptions])
8541
+ ..._optionalChain([farmConfig, 'access', _390 => _390.build, 'optionalAccess', _391 => _391.rollupOptions])
8634
8542
  }
8635
8543
  },
8636
8544
  css: farmConfig.css || userCss ? { ...farmConfig.css, ...userCss } : void 0,
@@ -8638,7 +8546,7 @@ function mergeFarmProductionViteConfig(farmConfig, userConfig = {}) {
8638
8546
  esbuild: typeof userEsbuild === "object" && farmConfig.esbuild !== false ? { ...userEsbuild, ...farmConfig.esbuild } : _nullishCoalesce(farmConfig.esbuild, () => ( userEsbuild)),
8639
8547
  ssr: {
8640
8548
  ...merged.ssr,
8641
- external: mergeExternal(_optionalChain([farmConfig, 'access', _384 => _384.ssr, 'optionalAccess', _385 => _385.external]), _optionalChain([userConfig, 'access', _386 => _386.ssr, 'optionalAccess', _387 => _387.external]))
8549
+ external: mergeExternal(_optionalChain([farmConfig, 'access', _392 => _392.ssr, 'optionalAccess', _393 => _393.external]), _optionalChain([userConfig, 'access', _394 => _394.ssr, 'optionalAccess', _395 => _395.external]))
8642
8550
  }
8643
8551
  };
8644
8552
  }
@@ -8710,9 +8618,4 @@ _chunkS3JO3N4Hcjs.__name.call(void 0, createFarmThemeCssPlugin, "createFarmTheme
8710
8618
 
8711
8619
 
8712
8620
 
8713
-
8714
-
8715
-
8716
-
8717
-
8718
- exports.resolveModuleSourcePath = resolveModuleSourcePath; exports.getFarmClientHydrationPlanOptions = getFarmClientHydrationPlanOptions; exports.describeSuppressedAsyncHydration = describeSuppressedAsyncHydration; exports.resolveFarmIsolatedClientHydrationMode = resolveFarmIsolatedClientHydrationMode; exports.hasUseClientDirective = hasUseClientDirective; exports.getIslandStrategyExport = getIslandStrategyExport; exports.stripUseClientDirective = stripUseClientDirective; exports.getClientModuleMetadata = getClientModuleMetadata; exports.getClientModuleHydrationPlan = getClientModuleHydrationPlan; exports.usesFarmServerTree = usesFarmServerTree; exports.createMarkdownPageHydrationPlanner = createMarkdownPageHydrationPlanner; exports.enforceFarmIsolatedHydrationRouteBudget = enforceFarmIsolatedHydrationRouteBudget; exports.isIsolatableClientBoundarySource = isIsolatableClientBoundarySource; exports.createFarmRouteRenderPlan = createFarmRouteRenderPlan; exports.getFarmFragmentCacheControl = getFarmFragmentCacheControl; exports.parseFarmLayoutChainHeader = parseFarmLayoutChainHeader; exports.getSharedLayoutPrefixLength = getSharedLayoutPrefixLength; exports.RouteManager = RouteManager; exports.resolveDevGlobalStylesheetHref = resolveDevGlobalStylesheetHref; exports.resolveFarmNotFoundComponentPath = resolveFarmNotFoundComponentPath; exports.farmFontImportsPlugin = farmFontImportsPlugin; exports.mergeFarmFontCss = mergeFarmFontCss; exports.DEFAULT_NOT_FOUND_STYLES = DEFAULT_NOT_FOUND_STYLES; exports.generateFarmIntegrationProviderClientCode = generateFarmIntegrationProviderClientCode; exports.generateFarmIntegrationProviderServerModules = generateFarmIntegrationProviderServerModules; exports.ServerRenderer = ServerRenderer; exports.FarmApp = FarmApp; exports.createFarmApp = createFarmApp; exports.SHARP_INSTALL_HINT = SHARP_INSTALL_HINT; exports.resolveFarmImageProviderForRuntime = resolveFarmImageProviderForRuntime; exports.resolveFarmImageServerRuntime = resolveFarmImageServerRuntime; exports.resolveFarmAppPackages = resolveFarmAppPackages; exports.collectFarmWebMCPTools = collectFarmWebMCPTools; exports.generateFarmClientPluginEntryCode = generateFarmClientPluginEntryCode; exports.resolveFarmClientCacheAdapterEntry = resolveFarmClientCacheAdapterEntry; exports.generateClientCachePersistenceCode = generateClientCachePersistenceCode; exports.FARM_LAYOUT_ELEMENT_CLIENT_SOURCE = FARM_LAYOUT_ELEMENT_CLIENT_SOURCE; exports.redactFarmDocsClientConfig = redactFarmDocsClientConfig; exports.isFarmDocsClientConfigModule = isFarmDocsClientConfigModule; exports.farmDocsClientConfigPlugin = farmDocsClientConfigPlugin; exports.loadTailwindVitePlugin = loadTailwindVitePlugin; exports.createFarmClientOptimizeDepsEntries = createFarmClientOptimizeDepsEntries; exports.createFarmClientOptimizeDepsConfig = createFarmClientOptimizeDepsConfig; exports.createFarmSourceAlias = createFarmSourceAlias; exports.mergeFarmViteConfig = mergeFarmViteConfig; exports.mergeFarmProductionViteConfig = mergeFarmProductionViteConfig; exports.createFarmThemeCssPlugin = createFarmThemeCssPlugin;
8621
+ exports.resolveModuleSourcePath = resolveModuleSourcePath; exports.getFarmClientHydrationPlanOptions = getFarmClientHydrationPlanOptions; exports.describeSuppressedAsyncHydration = describeSuppressedAsyncHydration; exports.resolveFarmIsolatedClientHydrationMode = resolveFarmIsolatedClientHydrationMode; exports.hasUseClientDirective = hasUseClientDirective; exports.getIslandStrategyExport = getIslandStrategyExport; exports.stripUseClientDirective = stripUseClientDirective; exports.getClientModuleMetadata = getClientModuleMetadata; exports.getClientModuleHydrationPlan = getClientModuleHydrationPlan; exports.usesFarmServerTree = usesFarmServerTree; exports.createMarkdownPageHydrationPlanner = createMarkdownPageHydrationPlanner; exports.enforceFarmIsolatedHydrationRouteBudget = enforceFarmIsolatedHydrationRouteBudget; exports.isIsolatableClientBoundarySource = isIsolatableClientBoundarySource; exports.RouteManager = RouteManager; exports.resolveDevGlobalStylesheetHref = resolveDevGlobalStylesheetHref; exports.resolveFarmNotFoundComponentPath = resolveFarmNotFoundComponentPath; exports.farmFontImportsPlugin = farmFontImportsPlugin; exports.mergeFarmFontCss = mergeFarmFontCss; exports.DEFAULT_NOT_FOUND_STYLES = DEFAULT_NOT_FOUND_STYLES; exports.generateFarmIntegrationProviderClientCode = generateFarmIntegrationProviderClientCode; exports.generateFarmIntegrationProviderServerModules = generateFarmIntegrationProviderServerModules; exports.ServerRenderer = ServerRenderer; exports.FarmApp = FarmApp; exports.createFarmApp = createFarmApp; exports.SHARP_INSTALL_HINT = SHARP_INSTALL_HINT; exports.resolveFarmImageProviderForRuntime = resolveFarmImageProviderForRuntime; exports.resolveFarmImageServerRuntime = resolveFarmImageServerRuntime; exports.resolveFarmAppPackages = resolveFarmAppPackages; exports.collectFarmWebMCPTools = collectFarmWebMCPTools; exports.generateFarmClientPluginEntryCode = generateFarmClientPluginEntryCode; exports.resolveFarmClientCacheAdapterEntry = resolveFarmClientCacheAdapterEntry; exports.generateClientCachePersistenceCode = generateClientCachePersistenceCode; exports.FARM_LAYOUT_ELEMENT_CLIENT_SOURCE = FARM_LAYOUT_ELEMENT_CLIENT_SOURCE; exports.redactFarmDocsClientConfig = redactFarmDocsClientConfig; exports.isFarmDocsClientConfigModule = isFarmDocsClientConfigModule; exports.farmDocsClientConfigPlugin = farmDocsClientConfigPlugin; exports.createFarmClientOptimizeDepsEntries = createFarmClientOptimizeDepsEntries; exports.createFarmClientOptimizeDepsConfig = createFarmClientOptimizeDepsConfig; exports.createFarmSourceAlias = createFarmSourceAlias; exports.mergeFarmViteConfig = mergeFarmViteConfig; exports.mergeFarmProductionViteConfig = mergeFarmProductionViteConfig; exports.createFarmThemeCssPlugin = createFarmThemeCssPlugin;