@farm.js/core 0.1.63 → 0.1.64

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 (186) hide show
  1. package/dist/{agent-mcp-handler-OV4WRFBL.cjs → agent-mcp-handler-OXT73ZBY.cjs} +5 -5
  2. package/dist/{agent-mcp-handler-7QMX2LUY.mjs → agent-mcp-handler-QLFDDTYN.mjs} +4 -4
  3. package/dist/{agent-mcp.d-CCQ-wKwg.d.mts → agent-mcp.d-CO_ABmNK.d.mts} +1 -1
  4. package/dist/{agent-mcp.d-DOJCBSh9.d.ts → agent-mcp.d-QD2WZ9BS.d.ts} +1 -1
  5. package/dist/agent-runtime.d.mts +1 -1
  6. package/dist/agent-runtime.d.ts +1 -1
  7. package/dist/analyzer-ODLF2Z6O.cjs +16 -0
  8. package/dist/{analyzer-WNPQPWFR.mjs → analyzer-Q3QXC6PD.mjs} +3 -2
  9. package/dist/api/route-manager.d.mts +3 -3
  10. package/dist/api/route-manager.d.ts +3 -3
  11. package/dist/api/runtime.d.mts +2 -2
  12. package/dist/api/runtime.d.ts +2 -2
  13. package/dist/api.d.mts +3 -3
  14. package/dist/api.d.ts +3 -3
  15. package/dist/{app-manifest.d-BaA0omsv.d.mts → app-manifest.d-BpKxiU_E.d.mts} +1 -1
  16. package/dist/{app-manifest.d-poayV4lq.d.ts → app-manifest.d-DDmNkYQQ.d.ts} +1 -1
  17. package/dist/app-markdown.cjs +4 -4
  18. package/dist/app-markdown.d.mts +2 -2
  19. package/dist/app-markdown.d.ts +2 -2
  20. package/dist/app-markdown.mjs +3 -3
  21. package/dist/{app.d-DdWxeIGU.d.mts → app.d-kuoVWhWM.d.mts} +4 -4
  22. package/dist/{app.d-D4Dn03E3.d.ts → app.d-x68Cwr0_.d.ts} +4 -4
  23. package/dist/{chunk-LT4VAF5Z.cjs → chunk-2C5L5RPM.cjs} +7 -6
  24. package/dist/{chunk-PVJX4UPA.cjs → chunk-3EBHJET2.cjs} +103 -98
  25. package/dist/{chunk-4DIKLG56.mjs → chunk-6NHSGVVA.mjs} +1 -1
  26. package/dist/{chunk-S2NUYHRY.mjs → chunk-6NNYPY5W.mjs} +327 -13
  27. package/dist/{chunk-PRFNLQSP.cjs → chunk-7XGWBPQQ.cjs} +4 -4
  28. package/dist/{chunk-U6WCUVSV.cjs → chunk-DUSHDZQL.cjs} +9 -9
  29. package/dist/{chunk-GVOMPU3Y.cjs → chunk-EL4364S2.cjs} +209 -32
  30. package/dist/{chunk-QN5WRQSQ.cjs → chunk-FAP7CX7C.cjs} +101 -101
  31. package/dist/{chunk-GPKBUME5.mjs → chunk-FH45OB37.mjs} +2 -2
  32. package/dist/{chunk-55U5QIXQ.mjs → chunk-FIR62CR3.mjs} +1 -1
  33. package/dist/{chunk-MEQN6DDA.cjs → chunk-FJWN7RV4.cjs} +5 -5
  34. package/dist/chunk-IOEXXZK3.mjs +88 -0
  35. package/dist/{chunk-Z74NNER4.cjs → chunk-JCPSA4X5.cjs} +135 -134
  36. package/dist/{chunk-YSXTNSXS.mjs → chunk-K7OZAVOI.mjs} +7 -6
  37. package/dist/{chunk-KVW2M6PI.mjs → chunk-KL7SHLQB.mjs} +1 -1
  38. package/dist/{chunk-RFYL5OLP.mjs → chunk-LQDLEWPO.mjs} +1 -1
  39. package/dist/{chunk-UZZ6IEQP.mjs → chunk-MESQF2JC.mjs} +2 -2
  40. package/dist/{chunk-5L7I6AMY.cjs → chunk-MG356ROI.cjs} +5 -5
  41. package/dist/{chunk-Y2YBNQ3D.cjs → chunk-N3Z3PLHC.cjs} +2 -2
  42. package/dist/{chunk-XICXQXYE.mjs → chunk-NNLFW3P4.mjs} +2 -2
  43. package/dist/{chunk-EYLC6GD6.cjs → chunk-NXFA7G3Y.cjs} +12 -12
  44. package/dist/{chunk-FNHN3RBD.cjs → chunk-O2XFIPNL.cjs} +1 -1
  45. package/dist/{chunk-BA2IA32Q.mjs → chunk-O4FWNLQK.mjs} +3 -3
  46. package/dist/{chunk-DZPR2W6U.cjs → chunk-O6L3YYPM.cjs} +5 -5
  47. package/dist/{chunk-LFFSDZ4Y.cjs → chunk-O7IEMY55.cjs} +3 -3
  48. package/dist/{chunk-6BJJYOFL.cjs → chunk-OLIGNTWU.cjs} +7 -7
  49. package/dist/{chunk-EENTT56C.mjs → chunk-OYF23QLG.mjs} +15 -14
  50. package/dist/{chunk-CBDRR3J3.mjs → chunk-RAH5MT53.mjs} +19 -14
  51. package/dist/{chunk-E72UD6ME.mjs → chunk-RVGSVQWT.mjs} +1 -1
  52. package/dist/{chunk-5IKQ7BIR.cjs → chunk-S25BQIFW.cjs} +16 -16
  53. package/dist/{chunk-LWWDTBGL.cjs → chunk-S7ZW72JH.cjs} +2 -2
  54. package/dist/{chunk-7FFW7DC4.mjs → chunk-SLYDIHLW.mjs} +4 -4
  55. package/dist/{chunk-LA6O5EL2.mjs → chunk-SNFTMSHX.mjs} +1 -1
  56. package/dist/{chunk-PCXIJKPM.mjs → chunk-TNBJ4LZG.mjs} +2 -2
  57. package/dist/{chunk-O27PLNQZ.cjs → chunk-UJ3R2AH2.cjs} +4 -4
  58. package/dist/{chunk-T4TBK5NY.mjs → chunk-VQ4NWOWO.mjs} +2 -2
  59. package/dist/{chunk-ZZ2QKCKW.mjs → chunk-WAY6LOQH.mjs} +1 -1
  60. package/dist/chunk-WBTHHTBO.cjs +88 -0
  61. package/dist/{chunk-O5FCWI6O.mjs → chunk-WFNAOWH4.mjs} +1 -1
  62. package/dist/{chunk-IWRLV46X.cjs → chunk-WMTBBQHY.cjs} +4 -4
  63. package/dist/{chunk-LA45FN37.mjs → chunk-WNYRYI4D.mjs} +10 -10
  64. package/dist/{chunk-CI4UNQHO.cjs → chunk-XBSKPLHF.cjs} +2 -2
  65. package/dist/{chunk-IOF4KXMP.mjs → chunk-XVWSDSUM.mjs} +201 -24
  66. package/dist/{chunk-ANXU3D32.cjs → chunk-XZLZ6YPP.cjs} +346 -32
  67. package/dist/{chunk-QAS7KE7J.cjs → chunk-Y5TOT5F6.cjs} +5 -5
  68. package/dist/{chunk-DPE53XWL.mjs → chunk-ZEXE4TGY.mjs} +1 -1
  69. package/dist/{client-component.d-CSEFlHfG.d.mts → client-component.d-D74pqdea.d.mts} +2 -2
  70. package/dist/{client-component.d-CQLvqLAJ.d.ts → client-component.d-D8VcypQA.d.ts} +2 -2
  71. package/dist/{client-plugins.d-BgPUYPc9.d.ts → client-plugins.d-CXElzotB.d.ts} +8 -1
  72. package/dist/{client-plugins.d-BTF0gZm4.d.mts → client-plugins.d-D4-6hNx7.d.mts} +8 -1
  73. package/dist/client-plugins.d.mts +1 -1
  74. package/dist/client-plugins.d.ts +1 -1
  75. package/dist/client.d.mts +6 -6
  76. package/dist/client.d.ts +6 -6
  77. package/dist/config.d.mts +1 -1
  78. package/dist/config.d.ts +1 -1
  79. package/dist/desktop.d.mts +2 -2
  80. package/dist/desktop.d.ts +2 -2
  81. package/dist/{devtools-HDKTYIZF.mjs → devtools-MX3FE733.mjs} +4 -4
  82. package/dist/{devtools-ZHN5JLVI.cjs → devtools-WET5NAKO.cjs} +5 -5
  83. package/dist/docs.cjs +7 -7
  84. package/dist/docs.d.mts +2 -2
  85. package/dist/docs.d.ts +2 -2
  86. package/dist/docs.mjs +6 -6
  87. package/dist/index.cjs +20 -19
  88. package/dist/{index.d-Coow7bD4.d.ts → index.d-A_x10zGS.d.ts} +1 -1
  89. package/dist/{index.d-Dbjx0ku7.d.mts → index.d-SSgYDv4D.d.mts} +1 -1
  90. package/dist/index.d.mts +16 -16
  91. package/dist/index.d.ts +16 -16
  92. package/dist/index.mjs +19 -18
  93. package/dist/integrations.d.mts +1 -1
  94. package/dist/integrations.d.ts +1 -1
  95. package/dist/internal/app-markdown-runtime.cjs +3 -3
  96. package/dist/internal/app-markdown-runtime.d.mts +2 -2
  97. package/dist/internal/app-markdown-runtime.d.ts +2 -2
  98. package/dist/internal/app-markdown-runtime.mjs +2 -2
  99. package/dist/internal/build-runtime.cjs +21 -20
  100. package/dist/internal/build-runtime.d.mts +3 -3
  101. package/dist/internal/build-runtime.d.ts +3 -3
  102. package/dist/internal/build-runtime.mjs +20 -19
  103. package/dist/internal/cli-runtime.cjs +6 -6
  104. package/dist/internal/cli-runtime.mjs +5 -5
  105. package/dist/internal/client-error-overlay.cjs +4 -4
  106. package/dist/internal/client-error-overlay.mjs +1 -1
  107. package/dist/internal/client-runtime.d.mts +4 -4
  108. package/dist/internal/client-runtime.d.ts +4 -4
  109. package/dist/internal/compression-runtime.d.mts +1 -1
  110. package/dist/internal/compression-runtime.d.ts +1 -1
  111. package/dist/internal/config-runtime.cjs +6 -6
  112. package/dist/internal/config-runtime.d.mts +4 -4
  113. package/dist/internal/config-runtime.d.ts +4 -4
  114. package/dist/internal/config-runtime.mjs +5 -5
  115. package/dist/internal/infra-analytics-runtime.cjs +9 -9
  116. package/dist/internal/infra-analytics-runtime.mjs +7 -7
  117. package/dist/internal/native-server-fns.cjs +5 -4
  118. package/dist/internal/native-server-fns.mjs +4 -3
  119. package/dist/internal/product-telemetry-runtime.cjs +3 -3
  120. package/dist/internal/product-telemetry-runtime.mjs +2 -2
  121. package/dist/internal/production-runtime.cjs +11 -11
  122. package/dist/internal/production-runtime.d.mts +13 -12
  123. package/dist/internal/production-runtime.d.ts +13 -12
  124. package/dist/internal/production-runtime.mjs +10 -10
  125. package/dist/markdown.cjs +2 -2
  126. package/dist/markdown.d.mts +1 -1
  127. package/dist/markdown.d.ts +1 -1
  128. package/dist/markdown.mjs +1 -1
  129. package/dist/middleware.d.mts +3 -3
  130. package/dist/middleware.d.ts +3 -3
  131. package/dist/mobile.d.mts +2 -2
  132. package/dist/mobile.d.ts +2 -2
  133. package/dist/{native-tree-AS5L3ID3.mjs → native-tree-BPEE2LAL.mjs} +2 -2
  134. package/dist/{native-tree-Z2WYUJEV.cjs → native-tree-WOX3JMBG.cjs} +3 -3
  135. package/dist/{navigation-delegate.d-Ca_BV0Wu.d.mts → navigation-delegate.d-DQVYKoaZ.d.mts} +1 -1
  136. package/dist/{navigation-delegate.d-aHiPI6GL.d.ts → navigation-delegate.d-GghbHJuK.d.ts} +1 -1
  137. package/dist/navigation.d.mts +4 -4
  138. package/dist/navigation.d.ts +4 -4
  139. package/dist/plugin.cjs +13 -13
  140. package/dist/plugin.d.mts +3 -3
  141. package/dist/plugin.d.ts +3 -3
  142. package/dist/plugin.mjs +12 -12
  143. package/dist/{production-runtime.d-C0rF7a10.d.ts → production-runtime.d-Bzns3NW9.d.ts} +1 -1
  144. package/dist/{production-runtime.d-CnAsSWgF.d.mts → production-runtime.d-DiFa5vHW.d.mts} +1 -1
  145. package/dist/{render-plan.d-BxeITFT1.d.ts → render-plan.d-CL_Ikfg_.d.ts} +1 -1
  146. package/dist/{render-plan.d-Z-93m5GZ.d.mts → render-plan.d-CcF0MeCf.d.mts} +1 -1
  147. package/dist/renderer-client.d.mts +4 -4
  148. package/dist/renderer-client.d.ts +4 -4
  149. package/dist/{request.d-X7Q1vmGF.d.ts → request.d-B1RnTLri.d.ts} +1 -1
  150. package/dist/{request.d-8_fMFNEb.d.mts → request.d-DarDOCk9.d.mts} +1 -1
  151. package/dist/request.d.mts +2 -2
  152. package/dist/request.d.ts +2 -2
  153. package/dist/{route-rendering.d-BUr3Jp8S.d.ts → route-rendering.d-BTUYCIj4.d.ts} +1 -1
  154. package/dist/{route-rendering.d-BInmBmul.d.mts → route-rendering.d-D_2Ual0-.d.mts} +1 -1
  155. package/dist/{router.d-crorSRiW.d.ts → router.d-CMANF6da.d.ts} +1 -1
  156. package/dist/{router.d-CZQmbpHx.d.mts → router.d-Cuv1jntg.d.mts} +1 -1
  157. package/dist/{routes.d-BknKQcTu.d.ts → routes.d-B6yFe6jm.d.ts} +1 -1
  158. package/dist/{routes.d-D1IrO9KK.d.mts → routes.d-c2HKfrfL.d.mts} +1 -1
  159. package/dist/routes.d.mts +1 -1
  160. package/dist/routes.d.ts +1 -1
  161. package/dist/{rsc-pipeline-3MPRULGA.mjs → rsc-pipeline-3LNVP2OO.mjs} +5 -5
  162. package/dist/{rsc-pipeline-RHEZNBFQ.cjs → rsc-pipeline-G5WELVW3.cjs} +6 -6
  163. package/dist/{runtime-OZKFZQCU.cjs → runtime-DMEULPE7.cjs} +21 -10
  164. package/dist/{runtime-X5UR7VHP.mjs → runtime-HQJ2LLQL.mjs} +19 -8
  165. package/dist/{runtime.d-CCsjTZJW.d.ts → runtime.d-C3RQUj6_.d.ts} +1 -1
  166. package/dist/{runtime.d-CETtpLb-.d.mts → runtime.d-wvh4ngU0.d.mts} +1 -1
  167. package/dist/server-plugins.d.mts +2 -2
  168. package/dist/server-plugins.d.ts +2 -2
  169. package/dist/server.cjs +30 -30
  170. package/dist/server.d.mts +9 -9
  171. package/dist/server.d.ts +9 -9
  172. package/dist/server.mjs +15 -15
  173. package/dist/{spa-router.d-CtSHzXlC.d.mts → spa-router.d-WU_qS5gJ.d.mts} +2 -2
  174. package/dist/{spa-router.d-CCADbSqJ.d.ts → spa-router.d-m8H_Kl_B.d.ts} +2 -2
  175. package/dist/testing.d.mts +1 -1
  176. package/dist/testing.d.ts +1 -1
  177. package/dist/{utils.d-CjyE-npA.d.ts → utils.d-C9dQD5Zg.d.ts} +1 -1
  178. package/dist/{utils.d-zFPHKFFJ.d.mts → utils.d-W9IiEqmW.d.mts} +1 -1
  179. package/dist/version.cjs +2 -2
  180. package/dist/version.mjs +1 -1
  181. package/dist/vite.cjs +13 -13
  182. package/dist/vite.d.mts +4 -4
  183. package/dist/vite.d.ts +4 -4
  184. package/dist/vite.mjs +12 -12
  185. package/package.json +1 -1
  186. package/dist/analyzer-KEA5JVDR.cjs +0 -15
@@ -892,13 +892,14 @@ function extractHtmlTitle(html) {
892
892
  function readHtmlContentRegion(html) {
893
893
  return extractHtmlBody(_readFarmRenderedHtml(html));
894
894
  }
895
- function _readFarmRenderedHtml(html) {
895
+ function _readFarmRenderedHtml(html, options = {}) {
896
896
  const streamed = readStreamedBoundaryInstructions(html);
897
897
  return removeHiddenElements(
898
898
  resolveStreamedBoundaries(
899
899
  html.replace(/<script\b[^>]*>[\s\S]*?<\/script>/gi, "").replace(/<style\b[^>]*>[\s\S]*?<\/style>/gi, "").replace(/<noscript\b[^>]*>[\s\S]*?<\/noscript>/gi, ""),
900
900
  streamed
901
- ).replace(/<!--[\s\S]*?-->/g, "")
901
+ ).replace(/<!--[\s\S]*?-->/g, ""),
902
+ options.keepAriaHidden
902
903
  );
903
904
  }
904
905
  function extractHtmlBody(html) {
@@ -1182,7 +1183,7 @@ var VOID_TAGS = /* @__PURE__ */ new Set([
1182
1183
  "track",
1183
1184
  "wbr"
1184
1185
  ]);
1185
- function removeHiddenElements(html) {
1186
+ function removeHiddenElements(html, keepAriaHidden = false) {
1186
1187
  if (!/hidden/i.test(html)) return html;
1187
1188
  const openingTag = /<([a-zA-Z][\w:-]*)((?:[^>"']|"[^"]*"|'[^']*')*)>/g;
1188
1189
  let closingTags;
@@ -1191,7 +1192,7 @@ function removeHiddenElements(html) {
1191
1192
  let match;
1192
1193
  while (match = openingTag.exec(html)) {
1193
1194
  const [tag, name, attributes] = match;
1194
- if (!isHiddenElement(attributes)) continue;
1195
+ if (!isHiddenElement(attributes, keepAriaHidden)) continue;
1195
1196
  const start = match.index;
1196
1197
  let end = start + tag.length;
1197
1198
  if (!VOID_TAGS.has(name.toLowerCase()) && !isSelfClosingTag(tag)) {
@@ -1206,13 +1207,13 @@ function removeHiddenElements(html) {
1206
1207
  }
1207
1208
  return result + html.slice(cursor);
1208
1209
  }
1209
- function isHiddenElement(attributes) {
1210
+ function isHiddenElement(attributes, keepAriaHidden = false) {
1210
1211
  const attribute = /([^\s"'=<>/]+)(?:\s*=\s*(?:"([^"]*)"|'([^']*)'|([^\s"'=<>`]+)))?/g;
1211
1212
  let match;
1212
1213
  while (match = attribute.exec(attributes)) {
1213
1214
  const name = match[1].toLowerCase();
1214
1215
  const value = (match[2] ?? match[3] ?? match[4] ?? "").trim().toLowerCase();
1215
- if (name === "aria-hidden" && value === "true") return true;
1216
+ if (name === "aria-hidden" && value === "true" && !keepAriaHidden) return true;
1216
1217
  if (name === "hidden" && value !== "until-found") return true;
1217
1218
  }
1218
1219
  return false;
@@ -3,7 +3,7 @@ import {
3
3
  getFarmMarkdownMirrorPath,
4
4
  isFarmMarkdownMirrorExposed,
5
5
  matchesFarmMarkdownRoutePattern
6
- } from "./chunk-YSXTNSXS.mjs";
6
+ } from "./chunk-K7OZAVOI.mjs";
7
7
  import {
8
8
  applyFarmBasePath
9
9
  } from "./chunk-SF3JB56B.mjs";
@@ -1,5 +1,5 @@
1
1
  // package.json
2
- var version = "0.1.63";
2
+ var version = "0.1.64";
3
3
 
4
4
  // src/version.ts
5
5
  var FARM_VERSION = version;
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  collectFarmLlmsTxtPages
3
- } from "./chunk-KVW2M6PI.mjs";
3
+ } from "./chunk-KL7SHLQB.mjs";
4
4
  import {
5
5
  getFarmMarkdownMirrorPath,
6
6
  isFarmMarkdownMirrorExposed
7
- } from "./chunk-YSXTNSXS.mjs";
7
+ } from "./chunk-K7OZAVOI.mjs";
8
8
  import {
9
9
  _listFarmMCPCatalogs,
10
10
  _listFarmRegisteredMCPServers
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
- var _chunkEYLC6GD6cjs = require('./chunk-EYLC6GD6.cjs');
3
+ var _chunkNXFA7G3Ycjs = require('./chunk-NXFA7G3Y.cjs');
4
4
 
5
5
 
6
- var _chunkLT4VAF5Zcjs = require('./chunk-LT4VAF5Z.cjs');
6
+ var _chunk2C5L5RPMcjs = require('./chunk-2C5L5RPM.cjs');
7
7
 
8
8
 
9
9
  var _chunkEVIWKPJVcjs = require('./chunk-EVIWKPJV.cjs');
@@ -75,7 +75,7 @@ function resolveFarmInfraAnalytics(env = processEnv()) {
75
75
  };
76
76
  }
77
77
  function classifyFarmInfraAgent(userAgent) {
78
- return _chunkLT4VAF5Zcjs.classifyFarmAgent.call(void 0, userAgent);
78
+ return _chunk2C5L5RPMcjs.classifyFarmAgent.call(void 0, userAgent);
79
79
  }
80
80
  function routeTemplate(pattern) {
81
81
  return typeof pattern === "string" && pattern.length <= 256 && /^\/(?!\/)[a-zA-Z0-9_./:[\]()*-]*$/.test(pattern) ? pattern : "/[unmatched]";
@@ -273,7 +273,7 @@ function requestEvent(metadata, method, status, durationMs) {
273
273
  id: uuid(),
274
274
  requestId: metadata.id,
275
275
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
276
- route: routeTemplate(_chunkEYLC6GD6cjs.getFarmRouteLabel.call(void 0, metadata.route)),
276
+ route: routeTemplate(_chunkNXFA7G3Ycjs.getFarmRouteLabel.call(void 0, metadata.route)),
277
277
  agent: metadata.agent,
278
278
  kind: "request",
279
279
  method,
@@ -286,7 +286,7 @@ function toolEvent(metadata, event) {
286
286
  id: uuid(),
287
287
  requestId: metadata.id,
288
288
  timestamp: (/* @__PURE__ */ new Date()).toISOString(),
289
- route: routeTemplate(_chunkEYLC6GD6cjs.getFarmRouteLabel.call(void 0, metadata.route)),
289
+ route: routeTemplate(_chunkNXFA7G3Ycjs.getFarmRouteLabel.call(void 0, metadata.route)),
290
290
  agent: metadata.agent,
291
291
  kind: "mcp.tool",
292
292
  tool: event.tool,
@@ -7,7 +7,7 @@ var _chunkVVTJTMGQcjs = require('./chunk-VVTJTMGQ.cjs');
7
7
  var _chunkXVSBALOYcjs = require('./chunk-XVSBALOY.cjs');
8
8
 
9
9
 
10
- var _chunkU6WCUVSVcjs = require('./chunk-U6WCUVSV.cjs');
10
+ var _chunkDUSHDZQLcjs = require('./chunk-DUSHDZQL.cjs');
11
11
 
12
12
 
13
13
 
@@ -114,7 +114,7 @@ async function createFarmRscViteConfig(userConfig, options) {
114
114
  server: { environmentName: "rsc" },
115
115
  config: {
116
116
  preset: options.preset,
117
- outputDir: options.outputDir && _chunkU6WCUVSVcjs.resolveDeployOutputPath.call(void 0, root, options.outputDir)
117
+ outputDir: options.outputDir && _chunkDUSHDZQLcjs.resolveDeployOutputPath.call(void 0, root, options.outputDir)
118
118
  }
119
119
  })
120
120
  ]
@@ -1,9 +1,9 @@
1
1
  import {
2
2
  getFarmRouteLabel
3
- } from "./chunk-7FFW7DC4.mjs";
3
+ } from "./chunk-SLYDIHLW.mjs";
4
4
  import {
5
5
  classifyFarmAgent
6
- } from "./chunk-YSXTNSXS.mjs";
6
+ } from "./chunk-K7OZAVOI.mjs";
7
7
  import {
8
8
  onFarmEvent
9
9
  } from "./chunk-2DA7CLY7.mjs";
@@ -1,17 +1,17 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
3
 
4
- var _chunkQAS7KE7Jcjs = require('./chunk-QAS7KE7J.cjs');
4
+ var _chunkY5TOT5F6cjs = require('./chunk-Y5TOT5F6.cjs');
5
5
 
6
6
 
7
- var _chunkLWWDTBGLcjs = require('./chunk-LWWDTBGL.cjs');
7
+ var _chunkS7ZW72JHcjs = require('./chunk-S7ZW72JH.cjs');
8
8
 
9
9
 
10
10
  var _chunkBTVDYS4Bcjs = require('./chunk-BTVDYS4B.cjs');
11
11
 
12
12
 
13
13
 
14
- var _chunkLT4VAF5Zcjs = require('./chunk-LT4VAF5Z.cjs');
14
+ var _chunk2C5L5RPMcjs = require('./chunk-2C5L5RPM.cjs');
15
15
 
16
16
 
17
17
  var _chunk2KMIJDY6cjs = require('./chunk-2KMIJDY6.cjs');
@@ -29,7 +29,7 @@ var _chunk2OF5RPVUcjs = require('./chunk-2OF5RPVU.cjs');
29
29
  var _chunkCFG4QERRcjs = require('./chunk-CFG4QERR.cjs');
30
30
 
31
31
 
32
- var _chunkFNHN3RBDcjs = require('./chunk-FNHN3RBD.cjs');
32
+ var _chunkO2XFIPNLcjs = require('./chunk-O2XFIPNL.cjs');
33
33
 
34
34
 
35
35
  var _chunkD22BUQKWcjs = require('./chunk-D22BUQKW.cjs');
@@ -165,7 +165,7 @@ function createFarmAiCatalogResponse(request, input = {}, requestUrl) {
165
165
  if (_chunkCFG4QERRcjs.matchesFarmIfNoneMatch.call(void 0, request.headers.get("if-none-match"), etag)) {
166
166
  return new Response(null, { status: 304, headers });
167
167
  }
168
- _chunkLT4VAF5Zcjs.emitFarmAgentRead.call(void 0, request, card ? "mcp-server-card" : "ai-catalog", 200);
168
+ _chunk2C5L5RPMcjs.emitFarmAgentRead.call(void 0, request, card ? "mcp-server-card" : "ai-catalog", 200);
169
169
  return new Response(method === "HEAD" ? null : body, { status: 200, headers });
170
170
  }
171
171
  function corsHeaders() {
@@ -233,7 +233,7 @@ function createFarmApiCatalogResponse(method, input, request) {
233
233
  headers: { Allow: "GET, HEAD", "Content-Type": "text/plain; charset=utf-8" }
234
234
  });
235
235
  }
236
- if (request) _chunkLT4VAF5Zcjs.emitFarmAgentRead.call(void 0, request, "api-catalog", 200);
236
+ if (request) _chunk2C5L5RPMcjs.emitFarmAgentRead.call(void 0, request, "api-catalog", 200);
237
237
  const catalog = createFarmApiCatalog(input);
238
238
  return new Response(upperMethod === "HEAD" ? null : JSON.stringify(catalog), {
239
239
  status: 200,
@@ -288,7 +288,7 @@ function createFarmAppManifest(input) {
288
288
  return {
289
289
  schemaVersion: 1,
290
290
  app: app ? {
291
- ...app.version ? { farm: _chunkFNHN3RBDcjs.FARM_VERSION } : {},
291
+ ...app.version ? { farm: _chunkO2XFIPNLcjs.FARM_VERSION } : {},
292
292
  ...app.renderer ? { renderer: input.renderer } : {},
293
293
  basePath: input.basePath,
294
294
  ...app.build ? { build: input.build } : {}
@@ -319,7 +319,7 @@ function resolveFarmSiteUrl() {
319
319
  asUrl(read("RAILWAY_PUBLIC_DOMAIN"))
320
320
  ];
321
321
  for (const candidate of candidates) {
322
- const origin = candidate ? _chunkLWWDTBGLcjs.normalizeFarmProductionSiteOrigin.call(void 0, candidate) : void 0;
322
+ const origin = candidate ? _chunkS7ZW72JHcjs.normalizeFarmProductionSiteOrigin.call(void 0, candidate) : void 0;
323
323
  if (origin) return origin;
324
324
  }
325
325
  return null;
@@ -374,7 +374,7 @@ function listDefaultServer(input) {
374
374
  authorization: "none",
375
375
  resources: [],
376
376
  prompts: [],
377
- tools: _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_TOOLS.map((tool) => ({
377
+ tools: _chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_TOOLS.map((tool) => ({
378
378
  name: tool.name,
379
379
  title: tool.title,
380
380
  description: tool.description,
@@ -434,7 +434,7 @@ function listFarmBuiltInRoutePaths(input) {
434
434
  ...agent.manifest !== false ? [FARM_APP_MANIFEST_PATH, FARM_APP_MANIFEST_LEGACY_PATH] : [],
435
435
  ...agent.apiCatalog ? [FARM_API_CATALOG_PATH] : [],
436
436
  ...agent.aiCatalog !== false ? [FARM_AI_CATALOG_PATH, FARM_ARD_PATH] : [],
437
- ...agent.mcp === true ? [_chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PATH, `${_chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PATH}${FARM_MCP_SERVER_CARD_SUFFIX}`] : [],
437
+ ...agent.mcp === true ? [_chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_PATH, `${_chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_PATH}${FARM_MCP_SERVER_CARD_SUFFIX}`] : [],
438
438
  ..._optionalChain([agent, 'access', _43 => _43.llmsTxt, 'optionalAccess', _44 => _44.enabled]) ? ["/llms.txt"] : [],
439
439
  ..._optionalChain([agent, 'access', _45 => _45.llmsTxt, 'optionalAccess', _46 => _46.enabled]) && agent.llmsTxt.full ? ["/llms-full.txt"] : [],
440
440
  ..._optionalChain([agent, 'access', _47 => _47.sitemap, 'optionalAccess', _48 => _48.enabled]) ? ["/sitemap.xml"] : [],
@@ -473,7 +473,7 @@ function resolveFarmDocsRouteLabel(routePathname, docs) {
473
473
  for (const entry of entries) {
474
474
  const base = entry === "/" ? "" : entry;
475
475
  if (page === entry || entry === "/" && page === "/index") {
476
- return markdown ? _chunkLT4VAF5Zcjs.getFarmMarkdownMirrorPath.call(void 0, entry) : entry;
476
+ return markdown ? _chunk2C5L5RPMcjs.getFarmMarkdownMirrorPath.call(void 0, entry) : entry;
477
477
  }
478
478
  if (page.startsWith(`${base}/`)) return `${base}/[...slug]${markdown ? ".md" : ""}`;
479
479
  }
@@ -493,7 +493,7 @@ function resolveFarmMarkdownRouteLabel(routePathname, matchPagePattern) {
493
493
  if (!routePathname.toLowerCase().endsWith(".md")) return null;
494
494
  const page = routePathname === "/index.md" ? "/" : routePathname.slice(0, -".md".length) || "/";
495
495
  const pattern = matchPagePattern(page);
496
- return pattern ? _chunkLT4VAF5Zcjs.getFarmMarkdownMirrorPath.call(void 0, pattern) : null;
496
+ return pattern ? _chunk2C5L5RPMcjs.getFarmMarkdownMirrorPath.call(void 0, pattern) : null;
497
497
  }
498
498
 
499
499
 
@@ -1,5 +1,5 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true});// package.json
2
- var version = "0.1.63";
2
+ var version = "0.1.64";
3
3
 
4
4
  // src/version.ts
5
5
  var FARM_VERSION = version;
@@ -25,7 +25,7 @@ import {
25
25
  resolveFarmAgentSitemap,
26
26
  resolveFarmNoindexPreviews,
27
27
  resolveFarmPerformanceConfig
28
- } from "./chunk-T4TBK5NY.mjs";
28
+ } from "./chunk-VQ4NWOWO.mjs";
29
29
  import {
30
30
  farmCspBlocksFrameworkInlineScripts,
31
31
  getFarmSecurityHeader,
@@ -36,7 +36,7 @@ import {
36
36
  } from "./chunk-SQ5O7I3L.mjs";
37
37
  import {
38
38
  resolveFarmLlmsTxtConfig
39
- } from "./chunk-KVW2M6PI.mjs";
39
+ } from "./chunk-KL7SHLQB.mjs";
40
40
  import {
41
41
  loadFarmConfigFile,
42
42
  resolveFarmLayers
@@ -53,7 +53,7 @@ import {
53
53
  } from "./chunk-UIJOLBUL.mjs";
54
54
  import {
55
55
  resolveMarkdownConfig
56
- } from "./chunk-YSXTNSXS.mjs";
56
+ } from "./chunk-K7OZAVOI.mjs";
57
57
  import {
58
58
  bundleNodeModule
59
59
  } from "./chunk-VFXE6NWR.mjs";
@@ -1,9 +1,9 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } } function _optionalChain(ops) { let lastAccessLHS = undefined; let value = ops[0]; let i = 1; while (i < ops.length) { const op = ops[i]; const fn = ops[i + 1]; i += 2; if ((op === 'optionalAccess' || op === 'optionalCall') && value == null) { return undefined; } if (op === 'access' || op === 'optionalAccess') { lastAccessLHS = value; value = fn(value); } else if (op === 'call' || op === 'optionalCall') { value = fn((...args) => value.call(lastAccessLHS, ...args)); lastAccessLHS = undefined; } } return value; }
2
2
 
3
- var _chunkMEQN6DDAcjs = require('./chunk-MEQN6DDA.cjs');
3
+ var _chunkFJWN7RV4cjs = require('./chunk-FJWN7RV4.cjs');
4
4
 
5
5
 
6
- var _chunkLT4VAF5Zcjs = require('./chunk-LT4VAF5Z.cjs');
6
+ var _chunk2C5L5RPMcjs = require('./chunk-2C5L5RPM.cjs');
7
7
 
8
8
 
9
9
  var _chunkD22BUQKWcjs = require('./chunk-D22BUQKW.cjs');
@@ -166,12 +166,12 @@ function createFarmDefaultSitemap(sources, options) {
166
166
  for (const source of sources) {
167
167
  const path = source.pattern;
168
168
  if (path.includes("[") || path.includes("(") || entries.has(path)) continue;
169
- if (include.length && !include.some((pattern) => _chunkLT4VAF5Zcjs.matchesFarmMarkdownRoutePattern.call(void 0, pattern, path))) {
169
+ if (include.length && !include.some((pattern) => _chunk2C5L5RPMcjs.matchesFarmMarkdownRoutePattern.call(void 0, pattern, path))) {
170
170
  continue;
171
171
  }
172
- if (exclude.some((pattern) => _chunkLT4VAF5Zcjs.matchesFarmMarkdownRoutePattern.call(void 0, pattern, path))) continue;
172
+ if (exclude.some((pattern) => _chunk2C5L5RPMcjs.matchesFarmMarkdownRoutePattern.call(void 0, pattern, path))) continue;
173
173
  const module = isRecord(source.module) ? source.module : void 0;
174
- if (_chunkMEQN6DDAcjs.isFarmMetadataNoIndex.call(void 0, _optionalChain([module, 'optionalAccess', _2 => _2.metadata]))) continue;
174
+ if (_chunkFJWN7RV4cjs.isFarmMetadataNoIndex.call(void 0, _optionalChain([module, 'optionalAccess', _2 => _2.metadata]))) continue;
175
175
  if (_optionalChain([module, 'optionalAccess', _3 => _3.__farmRouteGuard])) continue;
176
176
  entries.set(path, {
177
177
  url: new URL(_chunkD22BUQKWcjs.applyFarmBasePath.call(void 0, path, options.basePath), base).href,
@@ -1,7 +1,7 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } function _nullishCoalesce(lhs, rhsFn) { if (lhs != null) { return lhs; } else { return rhsFn(); } }
2
2
 
3
3
 
4
- var _chunkANXU3D32cjs = require('./chunk-ANXU3D32.cjs');
4
+ var _chunkXZLZ6YPPcjs = require('./chunk-XZLZ6YPP.cjs');
5
5
 
6
6
 
7
7
  var _chunkPIUTGRDIcjs = require('./chunk-PIUTGRDI.cjs');
@@ -64,7 +64,7 @@ function findFarmNativeScreenFiles(appDirs) {
64
64
  }
65
65
  function collectFarmNativeServerFns(options) {
66
66
  const { root, srcDir } = options;
67
- const aliases = _chunkANXU3D32cjs.readAliases.call(void 0, root, srcDir);
67
+ const aliases = _chunkXZLZ6YPPcjs.readAliases.call(void 0, root, srcDir);
68
68
  const seen = /* @__PURE__ */ new Set();
69
69
  const found = /* @__PURE__ */ new Map();
70
70
  const queue = [...options.entries];
@@ -98,7 +98,7 @@ function collectFarmNativeServerFns(options) {
98
98
  }
99
99
  }
100
100
  for (const candidate of _nullishCoalesce(candidates, () => ( []))) {
101
- const resolved = _chunkANXU3D32cjs.resolveFile.call(void 0, candidate);
101
+ const resolved = _chunkXZLZ6YPPcjs.resolveFile.call(void 0, candidate);
102
102
  if (resolved && SCRIPT.test(resolved) && !resolved.includes(`${_path2.default.sep}node_modules${_path2.default.sep}`)) {
103
103
  queue.push(resolved);
104
104
  break;
@@ -2,7 +2,7 @@
2
2
 
3
3
 
4
4
 
5
- var _chunkQAS7KE7Jcjs = require('./chunk-QAS7KE7J.cjs');
5
+ var _chunkY5TOT5F6cjs = require('./chunk-Y5TOT5F6.cjs');
6
6
 
7
7
 
8
8
  var _chunkD22BUQKWcjs = require('./chunk-D22BUQKW.cjs');
@@ -36,10 +36,10 @@ async function handleFarmDefaultMCPRequest(request, context) {
36
36
  return transportError(403, "Cross-origin requests are not allowed.");
37
37
  }
38
38
  const protocolHeader = request.headers.get("mcp-protocol-version");
39
- if (protocolHeader && !_chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS.includes(protocolHeader.trim())) {
39
+ if (protocolHeader && !_chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS.includes(protocolHeader.trim())) {
40
40
  return transportError(
41
41
  400,
42
- `Unsupported MCP-Protocol-Version: ${protocolHeader.slice(0, 32)}. Supported: ${_chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS.join(", ")}.`
42
+ `Unsupported MCP-Protocol-Version: ${protocolHeader.slice(0, 32)}. Supported: ${_chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS.join(", ")}.`
43
43
  );
44
44
  }
45
45
  const contentType = _nullishCoalesce(request.headers.get("content-type"), () => ( ""));
@@ -95,7 +95,7 @@ async function dispatch(method, params, request, context) {
95
95
  switch (method) {
96
96
  case "initialize": {
97
97
  const requested = isRecord(params) ? params.protocolVersion : void 0;
98
- const protocolVersion = typeof requested === "string" && _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS.includes(requested) ? requested : _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS[0];
98
+ const protocolVersion = typeof requested === "string" && _chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS.includes(requested) ? requested : _chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_PROTOCOL_VERSIONS[0];
99
99
  return {
100
100
  protocolVersion,
101
101
  capabilities: { tools: { listChanged: false } },
@@ -103,7 +103,7 @@ async function dispatch(method, params, request, context) {
103
103
  name: context.server.name,
104
104
  version: context.server.version,
105
105
  ...context.server.title ? { title: context.server.title } : {},
106
- description: _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_DESCRIPTION
106
+ description: _chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_DESCRIPTION
107
107
  },
108
108
  instructions: INSTRUCTIONS
109
109
  };
@@ -111,7 +111,7 @@ async function dispatch(method, params, request, context) {
111
111
  case "ping":
112
112
  return {};
113
113
  case "tools/list":
114
- return { tools: _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_TOOLS };
114
+ return { tools: _chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_TOOLS };
115
115
  case "tools/call":
116
116
  return callTool(params, request, context);
117
117
  default:
@@ -122,7 +122,7 @@ async function callTool(params, request, context) {
122
122
  if (!isRecord(params) || typeof params.name !== "string") {
123
123
  throw new FarmMCPRequestError(INVALID_PARAMS, "tools/call needs a tool name.");
124
124
  }
125
- const tool = _chunkQAS7KE7Jcjs.FARM_DEFAULT_MCP_TOOLS.find(({ name }) => name === params.name);
125
+ const tool = _chunkY5TOT5F6cjs.FARM_DEFAULT_MCP_TOOLS.find(({ name }) => name === params.name);
126
126
  if (!tool) {
127
127
  throw new FarmMCPRequestError(INVALID_PARAMS, `Unknown tool: ${params.name.slice(0, 64)}`);
128
128
  }
@@ -31,14 +31,14 @@ import {
31
31
  import {
32
32
  collectFarmNativeServerFns,
33
33
  findFarmNativeScreenFiles
34
- } from "./chunk-4DIKLG56.mjs";
34
+ } from "./chunk-6NHSGVVA.mjs";
35
35
  import {
36
36
  assertFarmDocsAdapterServesNoGuardedPages,
37
37
  compileFarmDocsAdapterEdgeManifest,
38
38
  createFarmDocsAPIHandler,
39
39
  hasFarmDocsRuntimeAdapter,
40
40
  listFarmDocsAdapterPages
41
- } from "./chunk-GPKBUME5.mjs";
41
+ } from "./chunk-FH45OB37.mjs";
42
42
  import {
43
43
  FARM_DOCS_LAST_MODIFIED_MANIFEST,
44
44
  createFarmDocsHandler,
@@ -50,7 +50,7 @@ import {
50
50
  loadFarmDocsPage,
51
51
  resolveFarmDocsContentDir,
52
52
  toFarmDocsMarkdownPage
53
- } from "./chunk-DPE53XWL.mjs";
53
+ } from "./chunk-ZEXE4TGY.mjs";
54
54
  import {
55
55
  generateFarmDocsSearchClientRuntime,
56
56
  isFarmDocsSearchEnabled,
@@ -58,7 +58,7 @@ import {
58
58
  } from "./chunk-ALEUMLJN.mjs";
59
59
  import {
60
60
  FARM_PRERENDER_ENV
61
- } from "./chunk-XICXQXYE.mjs";
61
+ } from "./chunk-NNLFW3P4.mjs";
62
62
  import {
63
63
  loadFarmDocsEngine
64
64
  } from "./chunk-VE3FWJBO.mjs";
@@ -67,7 +67,7 @@ import {
67
67
  getDeployTargetForPreset,
68
68
  hasCustomFarmRouteContext,
69
69
  resolveDeployOutputPath
70
- } from "./chunk-BA2IA32Q.mjs";
70
+ } from "./chunk-O4FWNLQK.mjs";
71
71
  import {
72
72
  resolveFarmInstrumentationFile
73
73
  } from "./chunk-N35YPV4N.mjs";
@@ -111,7 +111,7 @@ import {
111
111
  usePackageClientBoundaryCacheFile,
112
112
  usesFarmServerTree,
113
113
  withPackageClientBoundaryCache
114
- } from "./chunk-LA45FN37.mjs";
114
+ } from "./chunk-WNYRYI4D.mjs";
115
115
  import {
116
116
  loadTailwindVitePlugin
117
117
  } from "./chunk-OM7WILES.mjs";
@@ -135,7 +135,7 @@ import {
135
135
  layoutsCanCoverSamePage,
136
136
  routeBoundaryCoversDirectory,
137
137
  stripRouteGroups
138
- } from "./chunk-PCXIJKPM.mjs";
138
+ } from "./chunk-TNBJ4LZG.mjs";
139
139
  import {
140
140
  FARM_NATIVE_TREE_CONTENT_TYPE
141
141
  } from "./chunk-LLZSYFOM.mjs";
@@ -149,15 +149,15 @@ import {
149
149
  listFarmBuiltInRoutePaths,
150
150
  resolveFarmApiCatalogInput,
151
151
  resolveFarmAppManifestInput
152
- } from "./chunk-7FFW7DC4.mjs";
152
+ } from "./chunk-SLYDIHLW.mjs";
153
153
  import {
154
154
  FARM_DEFAULT_MCP_PATH,
155
155
  createFarmDefaultMCPServer,
156
156
  farmConfigMountsMCP
157
- } from "./chunk-UZZ6IEQP.mjs";
157
+ } from "./chunk-MESQF2JC.mjs";
158
158
  import {
159
159
  isFarmPreviewDeploymentEnvironment
160
- } from "./chunk-LA6O5EL2.mjs";
160
+ } from "./chunk-SNFTMSHX.mjs";
161
161
  import {
162
162
  FARM_NATIVE_SERVER_FN_PLUGIN
163
163
  } from "./chunk-L4RTTTVE.mjs";
@@ -199,14 +199,14 @@ import {
199
199
  } from "./chunk-N33DLJBC.mjs";
200
200
  import {
201
201
  isFarmMarkdownPageFile
202
- } from "./chunk-E72UD6ME.mjs";
202
+ } from "./chunk-RVGSVQWT.mjs";
203
203
  import {
204
204
  resolveFarmMdxComponentsModulePath,
205
205
  resolveMdxConfig
206
206
  } from "./chunk-UIJOLBUL.mjs";
207
207
  import {
208
208
  getFarmMarkdownAlternatePath
209
- } from "./chunk-YSXTNSXS.mjs";
209
+ } from "./chunk-K7OZAVOI.mjs";
210
210
  import {
211
211
  applyFarmWorkflowVercelCrons,
212
212
  prepareFarmWorkflowsForNitro
@@ -264,7 +264,7 @@ import {
264
264
  } from "./chunk-2I6PUKWJ.mjs";
265
265
  import {
266
266
  FARM_VERSION
267
- } from "./chunk-RFYL5OLP.mjs";
267
+ } from "./chunk-LQDLEWPO.mjs";
268
268
  import {
269
269
  getFarmPresetRuntime
270
270
  } from "./chunk-UAQD67HM.mjs";
@@ -9340,8 +9340,9 @@ ${hasServerRuntimeIntegrations ? `
9340
9340
  // The mobile app's native-tier screens: the page, rendered as for a browser, read into a
9341
9341
  // tree of native views.
9342
9342
  const farmNativeStylesheets = JSON.parse(${JSON.stringify(FARM_NATIVE_STYLESHEETS_PLACEHOLDER)});
9343
+ // A POST is a form a native-tier screen submitted (native-tree.ts).
9343
9344
  if (
9344
- (request.method === "GET" || request.method === "HEAD") &&
9345
+ (request.method === "GET" || request.method === "HEAD" || request.method === "POST") &&
9345
9346
  request.headers.get("accept")?.includes(${JSON.stringify(FARM_NATIVE_TREE_CONTENT_TYPE)})
9346
9347
  ) {
9347
9348
  const treeResponse = await createFarmNativeTreeResponse({
@@ -42,7 +42,7 @@ import {
42
42
  rewriteFarmPackageClientImports,
43
43
  rewriteFarmReactServerImports,
44
44
  stripUseClientDirective
45
- } from "./chunk-LA45FN37.mjs";
45
+ } from "./chunk-WNYRYI4D.mjs";
46
46
  import {
47
47
  loadTailwindVitePlugin
48
48
  } from "./chunk-OM7WILES.mjs";
@@ -66,7 +66,7 @@ import {
66
66
  parseFarmLayoutChainHeader,
67
67
  renderFarmLocaleAlternateLinks,
68
68
  stripRouteGroups
69
- } from "./chunk-PCXIJKPM.mjs";
69
+ } from "./chunk-TNBJ4LZG.mjs";
70
70
  import {
71
71
  FARM_NATIVE_TREE_CONTENT_TYPE
72
72
  } from "./chunk-LLZSYFOM.mjs";
@@ -84,13 +84,13 @@ import {
84
84
  resolveFarmMCPRouteLabel,
85
85
  resolveFarmMarkdownRouteLabel,
86
86
  setFarmRouteLabel
87
- } from "./chunk-7FFW7DC4.mjs";
87
+ } from "./chunk-SLYDIHLW.mjs";
88
88
  import {
89
89
  FARM_DEFAULT_MCP_PATH
90
- } from "./chunk-UZZ6IEQP.mjs";
90
+ } from "./chunk-MESQF2JC.mjs";
91
91
  import {
92
92
  isFarmPreviewDeploymentEnvironment
93
- } from "./chunk-LA6O5EL2.mjs";
93
+ } from "./chunk-SNFTMSHX.mjs";
94
94
  import {
95
95
  createFarmServerFnBoundaryModule,
96
96
  isFarmServerFnBoundaryId,
@@ -137,10 +137,10 @@ import {
137
137
  FARM_PREVIEW_ROBOTS_TAG,
138
138
  resolveFarmAgentCrawlers,
139
139
  resolveFarmAgentSitemap
140
- } from "./chunk-T4TBK5NY.mjs";
140
+ } from "./chunk-VQ4NWOWO.mjs";
141
141
  import {
142
142
  resolveFarmLlmsTxtConfig
143
- } from "./chunk-KVW2M6PI.mjs";
143
+ } from "./chunk-KL7SHLQB.mjs";
144
144
  import {
145
145
  getFarmAppDirectories,
146
146
  getFarmLayerAliases,
@@ -157,7 +157,7 @@ import {
157
157
  createFarmMarkdownSourceResponse,
158
158
  isFarmMarkdownPageFile,
159
159
  normalizeFarmMarkdownRoutePath
160
- } from "./chunk-E72UD6ME.mjs";
160
+ } from "./chunk-RVGSVQWT.mjs";
161
161
  import {
162
162
  FARM_MARKDOWN_CONTENT_TYPE,
163
163
  createFarmMarkdownErrorBody,
@@ -166,7 +166,7 @@ import {
166
166
  getFarmMarkdownAlternatePath,
167
167
  getFarmMarkdownMirrorPath,
168
168
  resolveMarkdownMirrorTarget
169
- } from "./chunk-YSXTNSXS.mjs";
169
+ } from "./chunk-K7OZAVOI.mjs";
170
170
  import {
171
171
  resolveFarmRouteContext,
172
172
  withFarmRouteContext
@@ -257,7 +257,7 @@ import {
257
257
  } from "./chunk-QDWMCFTH.mjs";
258
258
  import {
259
259
  FARM_VERSION
260
- } from "./chunk-RFYL5OLP.mjs";
260
+ } from "./chunk-LQDLEWPO.mjs";
261
261
  import {
262
262
  DEFAULT_FARM_API_BASE_PATH
263
263
  } from "./chunk-W6QLRQ3V.mjs";
@@ -880,7 +880,7 @@ function loadFarmWorkflowsDevRuntime() {
880
880
  return import("./workflows.mjs");
881
881
  }
882
882
  function loadFarmDevtoolsSnapshotRuntime() {
883
- return import("./devtools-HDKTYIZF.mjs");
883
+ return import("./devtools-MX3FE733.mjs");
884
884
  }
885
885
  function loadFarmDevtoolsUIRuntime() {
886
886
  return import("./devtools-ui-CYBVFLPH.mjs");
@@ -2487,10 +2487,15 @@ window.__FARM_MANIFEST__ = ${inlineValue({
2487
2487
  return;
2488
2488
  }
2489
2489
  }
2490
- if (options.mobileClient && !viteModuleRequest && (requestMethod === "GET" || requestMethod === "HEAD") && req.headers.accept?.includes(FARM_NATIVE_TREE_CONTENT_TYPE)) {
2491
- const { createFarmNativeTreeResponse } = await import("./native-tree-AS5L3ID3.mjs");
2490
+ if (options.mobileClient && !viteModuleRequest && (requestMethod === "GET" || requestMethod === "HEAD" || requestMethod === "POST") && req.headers.accept?.includes(FARM_NATIVE_TREE_CONTENT_TYPE)) {
2491
+ const { createFarmNativeTreeResponse } = await import("./native-tree-BPEE2LAL.mjs");
2492
+ const treeBodyInit = requestMethod === "POST" ? { body: createFarmNodeRequestBodyStream(req), duplex: "half" } : {};
2492
2493
  const treeResponse = await createFarmNativeTreeResponse({
2493
- request: new Request(fullUrl, { method: requestMethod, headers: docsHeaders }),
2494
+ request: new Request(fullUrl, {
2495
+ method: requestMethod,
2496
+ headers: docsHeaders,
2497
+ ...treeBodyInit
2498
+ }),
2494
2499
  // As for the Markdown mirror: this server's own listener, redirects not followed.
2495
2500
  renderPage: (request) => createFarmDevServerDispatch(server)(
2496
2501
  new Request(request, {
@@ -6,7 +6,7 @@ import {
6
6
  _getFarmMarkdownPageCheckToken,
7
7
  createFarmMarkdownViewResponse,
8
8
  requestAcceptsMarkdown
9
- } from "./chunk-YSXTNSXS.mjs";
9
+ } from "./chunk-K7OZAVOI.mjs";
10
10
 
11
11
  // src/app-markdown-runtime.ts
12
12
  import { pathToFileURL } from "url";