@farm.js/core 0.2.1 → 0.2.2

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 (188) hide show
  1. package/dist/{agent-mcp.d--uQgDp_Q.d.ts → agent-mcp.d-DuZjglYX.d.ts} +1 -1
  2. package/dist/{agent-mcp.d-DpthRhqr.d.mts → agent-mcp.d-gI3ahrF6.d.mts} +1 -1
  3. package/dist/agent-runtime.d.mts +1 -1
  4. package/dist/agent-runtime.d.ts +1 -1
  5. package/dist/analyzer-ENHO4SA5.cjs +17 -0
  6. package/dist/{analyzer-GLFRODYV.mjs → analyzer-UXWYUTBK.mjs} +2 -2
  7. package/dist/api/node.d.mts +3 -3
  8. package/dist/api/node.d.ts +3 -3
  9. package/dist/api/route-manager.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 +4 -4
  14. package/dist/api.d.ts +4 -4
  15. package/dist/{app-manifest.d-DMgcFuXQ.d.ts → app-manifest.d-B3h89j6a.d.ts} +1 -1
  16. package/dist/{app-manifest.d-DXAvPjMw.d.mts → app-manifest.d-bHK9EGPI.d.mts} +1 -1
  17. package/dist/app-markdown.d.mts +2 -2
  18. package/dist/app-markdown.d.ts +2 -2
  19. package/dist/{app.d-htfGqq-d.d.ts → app.d-C3uyET_L.d.ts} +4 -4
  20. package/dist/{app.d-DG_-nN5y.d.mts → app.d-Cr7fXGvJ.d.mts} +4 -4
  21. package/dist/{chunk-HENYWY5J.cjs → chunk-2T4GGCQT.cjs} +2 -2
  22. package/dist/{chunk-PGU4SCIU.cjs → chunk-56F4CDKE.cjs} +124 -124
  23. package/dist/{chunk-V6ACETKR.cjs → chunk-5AOARZJT.cjs} +4 -4
  24. package/dist/{chunk-YQXLBYY2.cjs → chunk-5B2Y4EVS.cjs} +32 -8
  25. package/dist/{chunk-QI3UYN3P.cjs → chunk-5CG2UD6B.cjs} +12 -12
  26. package/dist/{chunk-QCVP22KW.cjs → chunk-5RYBQKBY.cjs} +3 -3
  27. package/dist/{chunk-BOHBFBRA.mjs → chunk-6VMBLDWY.mjs} +1 -1
  28. package/dist/{chunk-DVL3UVYT.mjs → chunk-6XABTMXR.mjs} +2 -2
  29. package/dist/chunk-7QGA6UX6.cjs +26 -0
  30. package/dist/{chunk-JZAGIXMB.cjs → chunk-A4AYTO2E.cjs} +1 -1
  31. package/dist/{chunk-V36K4TSU.mjs → chunk-ADKPJZPP.mjs} +1 -1
  32. package/dist/{chunk-OKZHPPBX.mjs → chunk-ALGAGXWB.mjs} +1 -1
  33. package/dist/{chunk-XSE4XJKY.cjs → chunk-B7CZ7T2I.cjs} +2 -2
  34. package/dist/{chunk-PVB5UYJT.cjs → chunk-BEAQVRMQ.cjs} +51 -51
  35. package/dist/{chunk-GEZ76JXD.cjs → chunk-FDS6U2NT.cjs} +3 -3
  36. package/dist/{chunk-P2THJDLH.mjs → chunk-FEWGKBMM.mjs} +16 -11
  37. package/dist/chunk-G7LNCHTS.mjs +21 -0
  38. package/dist/{chunk-L2KGQXFU.mjs → chunk-GKDOKES3.mjs} +1 -1
  39. package/dist/{chunk-XYCB3CXM.mjs → chunk-IEXZMDF4.mjs} +2 -2
  40. package/dist/{chunk-HBZQIRRM.mjs → chunk-JCERO6YF.mjs} +1 -1
  41. package/dist/{chunk-JJ22OI7J.cjs → chunk-JM5VSEYC.cjs} +2 -2
  42. package/dist/{chunk-MR64FNW6.cjs → chunk-L7Z6OAE2.cjs} +4 -4
  43. package/dist/{chunk-D5GFVHBV.mjs → chunk-MEXGQE4T.mjs} +5 -5
  44. package/dist/{chunk-RCJAOQWW.mjs → chunk-NPR6SCEV.mjs} +1 -1
  45. package/dist/{chunk-QJKGRUBR.mjs → chunk-Q4CPBKPT.mjs} +4 -4
  46. package/dist/{chunk-D2OU4CX2.cjs → chunk-SJQ24IB5.cjs} +6 -6
  47. package/dist/{chunk-SIJ3DREB.mjs → chunk-ST3U7XVO.mjs} +1 -1
  48. package/dist/{chunk-TI4BJFYX.mjs → chunk-TK2JJCP5.mjs} +10 -10
  49. package/dist/{chunk-LO5BNR6Y.mjs → chunk-W5T3ZAFU.mjs} +25 -1
  50. package/dist/{chunk-ADCVSTFV.cjs → chunk-WAQIO2VD.cjs} +2 -2
  51. package/dist/{chunk-W34OS5CK.cjs → chunk-ZND5D4IC.cjs} +142 -137
  52. package/dist/{chunk-E7ISZK3R.mjs → chunk-ZVT2F3JU.mjs} +1 -1
  53. package/dist/{client-component.d-DDbDw2yP.d.ts → client-component.d-BavTzqsn.d.ts} +1 -1
  54. package/dist/{client-component.d-D5JVDeQf.d.mts → client-component.d-X3j9FOZ2.d.mts} +1 -1
  55. package/dist/{client-plugins.d-BHqfH3DQ.d.ts → client-plugins.d-CqTr5IrQ.d.ts} +61 -1
  56. package/dist/{client-plugins.d-9jr2yWR3.d.mts → client-plugins.d-DnnAopKG.d.mts} +61 -1
  57. package/dist/client-plugins.d.mts +1 -1
  58. package/dist/client-plugins.d.ts +1 -1
  59. package/dist/client.d.mts +7 -7
  60. package/dist/client.d.ts +7 -7
  61. package/dist/config.d.mts +1 -1
  62. package/dist/config.d.ts +1 -1
  63. package/dist/desktop.cjs +5 -1
  64. package/dist/desktop.d.mts +8 -4
  65. package/dist/desktop.d.ts +8 -4
  66. package/dist/desktop.mjs +4 -0
  67. package/dist/{dev-guard-M3ZCDWCK.cjs → dev-guard-5NUIX6IZ.cjs} +4 -3
  68. package/dist/{dev-guard-TFVWJNIB.mjs → dev-guard-L42ZZRCZ.mjs} +2 -1
  69. package/dist/{devtools-F6Z436WU.cjs → devtools-4LMM3DDJ.cjs} +2 -2
  70. package/dist/{devtools-ZDBCJI44.mjs → devtools-RFVGDHXH.mjs} +1 -1
  71. package/dist/docs.cjs +3 -3
  72. package/dist/docs.d.mts +3 -3
  73. package/dist/docs.d.ts +3 -3
  74. package/dist/docs.mjs +2 -2
  75. package/dist/environment/vite.cjs +3 -3
  76. package/dist/environment/vite.mjs +2 -2
  77. package/dist/{handler.d-EtTSPkeO.d.mts → handler.d-BSlpYCDB.d.mts} +1 -1
  78. package/dist/{handler.d-Dq_bSEKC.d.ts → handler.d-DgX7gPO6.d.ts} +1 -1
  79. package/dist/{headers.d-BKwGD_uC.d.mts → headers.d-Cf8l5LMo.d.mts} +1 -1
  80. package/dist/{headers.d-CpIHLCEk.d.ts → headers.d-CmxW42R2.d.ts} +1 -1
  81. package/dist/index.cjs +15 -14
  82. package/dist/{index.d-DXtaU9OU.d.mts → index.d-7xoJqKRZ.d.mts} +1 -1
  83. package/dist/{index.d-CoRZKiHA.d.ts → index.d-BZZt7kxO.d.ts} +1 -1
  84. package/dist/index.d.mts +22 -22
  85. package/dist/index.d.ts +22 -22
  86. package/dist/index.mjs +14 -13
  87. package/dist/integrations/orm.d.mts +1 -1
  88. package/dist/integrations/orm.d.ts +1 -1
  89. package/dist/integrations.d.mts +1 -1
  90. package/dist/integrations.d.ts +1 -1
  91. package/dist/internal/app-markdown-runtime.d.mts +2 -2
  92. package/dist/internal/app-markdown-runtime.d.ts +2 -2
  93. package/dist/internal/build-runtime.cjs +17 -16
  94. package/dist/internal/build-runtime.d.mts +4 -4
  95. package/dist/internal/build-runtime.d.ts +4 -4
  96. package/dist/internal/build-runtime.mjs +16 -15
  97. package/dist/internal/cli-runtime.cjs +2 -2
  98. package/dist/internal/cli-runtime.d.mts +7 -7
  99. package/dist/internal/cli-runtime.d.ts +7 -7
  100. package/dist/internal/cli-runtime.mjs +1 -1
  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.d.mts +5 -5
  104. package/dist/internal/client-runtime.d.ts +5 -5
  105. package/dist/internal/compression-runtime.d.mts +1 -1
  106. package/dist/internal/compression-runtime.d.ts +1 -1
  107. package/dist/internal/config-runtime.cjs +5 -4
  108. package/dist/internal/config-runtime.d.mts +3 -3
  109. package/dist/internal/config-runtime.d.ts +3 -3
  110. package/dist/internal/config-runtime.mjs +4 -3
  111. package/dist/internal/infra-analytics-runtime.cjs +6 -6
  112. package/dist/internal/infra-analytics-runtime.mjs +4 -4
  113. package/dist/internal/native-server-fns.cjs +4 -4
  114. package/dist/internal/native-server-fns.mjs +3 -3
  115. package/dist/internal/product-telemetry-runtime.cjs +3 -3
  116. package/dist/internal/product-telemetry-runtime.mjs +2 -2
  117. package/dist/internal/production-runtime.cjs +4 -4
  118. package/dist/internal/production-runtime.d.mts +10 -10
  119. package/dist/internal/production-runtime.d.ts +10 -10
  120. package/dist/internal/production-runtime.mjs +3 -3
  121. package/dist/internal/spa-router.d.mts +3 -3
  122. package/dist/internal/spa-router.d.ts +3 -3
  123. package/dist/internal/start-manifest.d.mts +1 -1
  124. package/dist/internal/start-manifest.d.ts +1 -1
  125. package/dist/markdown.d.mts +1 -1
  126. package/dist/markdown.d.ts +1 -1
  127. package/dist/middleware.d.mts +1 -1
  128. package/dist/middleware.d.ts +1 -1
  129. package/dist/{mount.d-BzK2Z1pR.d.ts → mount.d-CD-xVBu7.d.ts} +1 -1
  130. package/dist/{mount.d-D-ynBlxU.d.mts → mount.d-Dd0xeRMl.d.mts} +1 -1
  131. package/dist/{navigation-delegate.d-DtsnFnNF.d.ts → navigation-delegate.d-Bses_F-y.d.ts} +1 -1
  132. package/dist/{navigation-delegate.d-aJh3ZmTY.d.mts → navigation-delegate.d-dBNg976E.d.mts} +1 -1
  133. package/dist/navigation.d.mts +4 -4
  134. package/dist/navigation.d.ts +4 -4
  135. package/dist/plugin.cjs +12 -11
  136. package/dist/plugin.d.mts +5 -5
  137. package/dist/plugin.d.ts +5 -5
  138. package/dist/plugin.mjs +11 -10
  139. package/dist/{render-plan.d-h8bkOQyh.d.ts → render-plan.d-DaIwnRK2.d.ts} +1 -1
  140. package/dist/{render-plan.d-C6nUIU2m.d.mts → render-plan.d-vOdZHHLI.d.mts} +1 -1
  141. package/dist/renderer-client.d.mts +5 -5
  142. package/dist/renderer-client.d.ts +5 -5
  143. package/dist/{request.d-CBEdJD5R.d.mts → request.d-B8U4pVFP.d.mts} +1 -1
  144. package/dist/{request.d-CrriEvxy.d.ts → request.d-CgXp3EEc.d.ts} +1 -1
  145. package/dist/request.d.mts +2 -2
  146. package/dist/request.d.ts +2 -2
  147. package/dist/{route-rendering.d-DgXpNk_c.d.mts → route-rendering.d-BQvNYQqu.d.mts} +1 -1
  148. package/dist/{route-rendering.d-C-ivf31T.d.ts → route-rendering.d-Di0AxFix.d.ts} +1 -1
  149. package/dist/{router.d-BRRPd5dE.d.ts → router.d-BJVGhSAJ.d.ts} +1 -1
  150. package/dist/{router.d-O5LrW9mZ.d.mts → router.d-hNedVdoB.d.mts} +1 -1
  151. package/dist/routes.d.mts +1 -1
  152. package/dist/routes.d.ts +1 -1
  153. package/dist/{rsc-pipeline-2DNM7UDA.cjs → rsc-pipeline-HT4G3QGT.cjs} +7 -6
  154. package/dist/{rsc-pipeline-HYINQPMW.mjs → rsc-pipeline-NCJ3NIE5.mjs} +6 -5
  155. package/dist/{runtime-M6GLD4CR.cjs → runtime-6UF5XKUP.cjs} +4 -4
  156. package/dist/{runtime-JP7L5KI7.mjs → runtime-VHXIEXL7.mjs} +2 -2
  157. package/dist/{runtime.d-DW_1avVi.d.ts → runtime.d-0R8nHCM6.d.ts} +1 -1
  158. package/dist/{runtime.d-DP8Sk9PM.d.mts → runtime.d-DpeuF_T-.d.mts} +1 -1
  159. package/dist/{schema-dependencies.d-Cedd7QUf.d.mts → schema-dependencies.d-_Wyey4Wv.d.mts} +1 -1
  160. package/dist/{schema-dependencies.d-C__RyTvW.d.ts → schema-dependencies.d-tkUHREqz.d.ts} +1 -1
  161. package/dist/{server-components-status.d-CdsEQbeM.d.ts → server-components-status.d-B2Z5WvO5.d.ts} +1 -1
  162. package/dist/{server-components-status.d-DN98yOT4.d.mts → server-components-status.d-sN7ju-ie.d.mts} +1 -1
  163. package/dist/server-plugins.d.mts +3 -3
  164. package/dist/server-plugins.d.ts +3 -3
  165. package/dist/server.cjs +37 -36
  166. package/dist/server.d.mts +11 -11
  167. package/dist/server.d.ts +11 -11
  168. package/dist/server.mjs +13 -12
  169. package/dist/{spa-router.d-FcDbBCrK.d.mts → spa-router.d-D3AtR2Bc.d.mts} +2 -2
  170. package/dist/{spa-router.d-BJWZAdrV.d.ts → spa-router.d-MjT6sGb9.d.ts} +2 -2
  171. package/dist/{ssg.d--uut8Gya.d.mts → ssg.d-B32Cp_XW.d.mts} +2 -2
  172. package/dist/{ssg.d-Cf9mC1rZ.d.ts → ssg.d-C1SNuPz5.d.ts} +2 -2
  173. package/dist/{store-core.d-h7o6V2kH.d.ts → store-core.d-BZ3YXs70.d.ts} +2 -2
  174. package/dist/{store-core.d-DgYlAo-e.d.mts → store-core.d-BbVdaoA0.d.mts} +2 -2
  175. package/dist/testing.d.mts +1 -1
  176. package/dist/testing.d.ts +1 -1
  177. package/dist/{utils.d-2lGEnyBc.d.ts → utils.d-Bjbm44fP.d.ts} +1 -1
  178. package/dist/{utils.d-DjFApBfE.d.mts → utils.d-CoLozp7-.d.mts} +1 -1
  179. package/dist/version.cjs +2 -2
  180. package/dist/version.mjs +1 -1
  181. package/dist/vite.cjs +12 -11
  182. package/dist/vite.d.mts +6 -6
  183. package/dist/vite.d.ts +6 -6
  184. package/dist/vite.mjs +11 -10
  185. package/package.json +1 -1
  186. package/dist/analyzer-KBVOHASA.cjs +0 -17
  187. /package/dist/{chunk-EIAA4W3M.cjs → chunk-COXMHCIV.cjs} +0 -0
  188. /package/dist/{chunk-H6MYRZ2U.mjs → chunk-JL2HNLMC.mjs} +0 -0
@@ -4,7 +4,7 @@
4
4
  var _chunkR6GOH5CHcjs = require('./chunk-R6GOH5CH.cjs');
5
5
 
6
6
 
7
- var _chunkHENYWY5Jcjs = require('./chunk-HENYWY5J.cjs');
7
+ var _chunk2T4GGCQTcjs = require('./chunk-2T4GGCQT.cjs');
8
8
 
9
9
 
10
10
  var _chunk6QCZWAGOcjs = require('./chunk-6QCZWAGO.cjs');
@@ -29,7 +29,7 @@ var _chunkH5AC3XSEcjs = require('./chunk-H5AC3XSE.cjs');
29
29
  var _chunk7GKZDRY2cjs = require('./chunk-7GKZDRY2.cjs');
30
30
 
31
31
 
32
- var _chunkJZAGIXMBcjs = require('./chunk-JZAGIXMB.cjs');
32
+ var _chunkA4AYTO2Ecjs = require('./chunk-A4AYTO2E.cjs');
33
33
 
34
34
 
35
35
  var _chunkTFCBJFP7cjs = require('./chunk-TFCBJFP7.cjs');
@@ -294,7 +294,7 @@ function createFarmAppManifest(input, registered = []) {
294
294
  return {
295
295
  schemaVersion: 1,
296
296
  app: app ? {
297
- ...app.version ? { farm: _chunkJZAGIXMBcjs.FARM_VERSION } : {},
297
+ ...app.version ? { farm: _chunkA4AYTO2Ecjs.FARM_VERSION } : {},
298
298
  ...app.renderer ? { renderer: input.renderer } : {},
299
299
  basePath: input.basePath,
300
300
  ...app.build ? { build: input.build } : {}
@@ -325,7 +325,7 @@ function resolveFarmSiteUrl() {
325
325
  asUrl(read("RAILWAY_PUBLIC_DOMAIN"))
326
326
  ];
327
327
  for (const candidate of candidates) {
328
- const origin = candidate ? _chunkHENYWY5Jcjs.normalizeFarmProductionSiteOrigin.call(void 0, candidate) : void 0;
328
+ const origin = candidate ? _chunk2T4GGCQTcjs.normalizeFarmProductionSiteOrigin.call(void 0, candidate) : void 0;
329
329
  if (origin) return origin;
330
330
  }
331
331
  return null;
@@ -1,10 +1,10 @@
1
1
  import {
2
2
  resolveFarmAppClientEntry,
3
3
  resolveFarmClientPlugins
4
- } from "./chunk-V36K4TSU.mjs";
4
+ } from "./chunk-ADKPJZPP.mjs";
5
5
  import {
6
6
  resolveFarmPlatform
7
- } from "./chunk-LO5BNR6Y.mjs";
7
+ } from "./chunk-W5T3ZAFU.mjs";
8
8
  import {
9
9
  collectSSGPages,
10
10
  matchSSGPage,
@@ -59,7 +59,7 @@ import {
59
59
  } from "./chunk-LP6DIYGA.mjs";
60
60
  import {
61
61
  listFarmMCPLlmsTxtLinks
62
- } from "./chunk-XYCB3CXM.mjs";
62
+ } from "./chunk-IEXZMDF4.mjs";
63
63
  import {
64
64
  FARM_DEFAULT_MCP_PATH,
65
65
  collectFarmDefaultMCPPages,
@@ -108,7 +108,7 @@ import {
108
108
  usesFarmServerTree,
109
109
  withFarmSourceSnapshot,
110
110
  withFarmSourceSnapshotAside
111
- } from "./chunk-E7ISZK3R.mjs";
111
+ } from "./chunk-ZVT2F3JU.mjs";
112
112
  import {
113
113
  _setDefaultFarmThemeConfig,
114
114
  getTheme
@@ -312,7 +312,7 @@ import {
312
312
  } from "./chunk-EILUVBKS.mjs";
313
313
  import {
314
314
  FARM_VERSION
315
- } from "./chunk-BOHBFBRA.mjs";
315
+ } from "./chunk-6VMBLDWY.mjs";
316
316
  import {
317
317
  normalizeFarmAPIConfig
318
318
  } from "./chunk-W6QLRQ3V.mjs";
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  FARM_VERSION
3
- } from "./chunk-BOHBFBRA.mjs";
3
+ } from "./chunk-6VMBLDWY.mjs";
4
4
 
5
5
  // src/deployment-environment.ts
6
6
  function isFarmProductionDeploymentEnvironment(env = process.env) {
@@ -3,19 +3,19 @@ import {
3
3
  } from "./chunk-RLEAVG6G.mjs";
4
4
  import {
5
5
  resolveDeployOutputPath
6
- } from "./chunk-H6MYRZ2U.mjs";
6
+ } from "./chunk-JL2HNLMC.mjs";
7
7
  import {
8
8
  farmDesktopDevGuardPlugin,
9
9
  loadFarmReactPlugin
10
- } from "./chunk-DVL3UVYT.mjs";
10
+ } from "./chunk-6XABTMXR.mjs";
11
11
  import {
12
12
  generateFarmClientPluginEntryCode,
13
13
  hasFarmServerRuntimePlugins,
14
14
  loadTailwindVitePlugin
15
- } from "./chunk-V36K4TSU.mjs";
15
+ } from "./chunk-ADKPJZPP.mjs";
16
16
  import {
17
17
  resolveFarmPlatform
18
- } from "./chunk-LO5BNR6Y.mjs";
18
+ } from "./chunk-W5T3ZAFU.mjs";
19
19
  import {
20
20
  FARM_RSC_INSTALL_HINT,
21
21
  findFarmAppPackageDir,
@@ -31,7 +31,7 @@ var _chunkPYPHM7AScjs = require('./chunk-PYPHM7AS.cjs');
31
31
  var _chunk7ZDLE77Pcjs = require('./chunk-7ZDLE77P.cjs');
32
32
 
33
33
 
34
- var _chunkJZAGIXMBcjs = require('./chunk-JZAGIXMB.cjs');
34
+ var _chunkA4AYTO2Ecjs = require('./chunk-A4AYTO2E.cjs');
35
35
 
36
36
 
37
37
  var _chunkUGL4BDNBcjs = require('./chunk-UGL4BDNB.cjs');
@@ -980,7 +980,7 @@ function usePackageScanCacheFile(file) {
980
980
  const stored = /* @__PURE__ */ new Map();
981
981
  try {
982
982
  const value = JSON.parse(_fs2.default.readFileSync(file, "utf8"));
983
- if (_optionalChain([value, 'optionalAccess', _68 => _68.schema]) === PACKAGE_SCAN_CACHE_SCHEMA && value.farm === _chunkJZAGIXMBcjs.FARM_VERSION && value.scans && typeof value.scans === "object") {
983
+ if (_optionalChain([value, 'optionalAccess', _68 => _68.schema]) === PACKAGE_SCAN_CACHE_SCHEMA && value.farm === _chunkA4AYTO2Ecjs.FARM_VERSION && value.scans && typeof value.scans === "object") {
984
984
  for (const [directory, scan] of Object.entries(value.scans)) {
985
985
  if (isStoredPackageScan(scan)) stored.set(directory, scan);
986
986
  }
@@ -1009,7 +1009,7 @@ function persistPackageScanCache() {
1009
1009
  _fs2.default.mkdirSync(_path2.default.dirname(cache2.file), { recursive: true });
1010
1010
  _fs2.default.writeFileSync(
1011
1011
  temporary,
1012
- JSON.stringify({ schema: PACKAGE_SCAN_CACHE_SCHEMA, farm: _chunkJZAGIXMBcjs.FARM_VERSION, scans })
1012
+ JSON.stringify({ schema: PACKAGE_SCAN_CACHE_SCHEMA, farm: _chunkA4AYTO2Ecjs.FARM_VERSION, scans })
1013
1013
  );
1014
1014
  _fs2.default.renameSync(temporary, cache2.file);
1015
1015
  cache2.dirty = false;
@@ -2322,7 +2322,7 @@ var PackageClientBoundaryCache = class {
2322
2322
  }
2323
2323
  const contents = JSON.stringify({
2324
2324
  schema: SCHEMA_VERSION,
2325
- farm: _chunkJZAGIXMBcjs.FARM_VERSION,
2325
+ farm: _chunkA4AYTO2Ecjs.FARM_VERSION,
2326
2326
  paths,
2327
2327
  entries
2328
2328
  });
@@ -2362,7 +2362,7 @@ function readStoredCache(file) {
2362
2362
  } catch (e38) {
2363
2363
  return null;
2364
2364
  }
2365
- if (!isRecord(value) || value.schema !== SCHEMA_VERSION || value.farm !== _chunkJZAGIXMBcjs.FARM_VERSION) {
2365
+ if (!isRecord(value) || value.schema !== SCHEMA_VERSION || value.farm !== _chunkA4AYTO2Ecjs.FARM_VERSION) {
2366
2366
  return null;
2367
2367
  }
2368
2368
  const { paths, entries } = value;
@@ -2373,7 +2373,7 @@ function readStoredCache(file) {
2373
2373
  const usable = variants.filter((entry) => isStoredEntry(entry, paths.length));
2374
2374
  if (usable.length > 0) valid[key] = usable;
2375
2375
  }
2376
- return { schema: SCHEMA_VERSION, farm: _chunkJZAGIXMBcjs.FARM_VERSION, paths, entries: valid };
2376
+ return { schema: SCHEMA_VERSION, farm: _chunkA4AYTO2Ecjs.FARM_VERSION, paths, entries: valid };
2377
2377
  }
2378
2378
  function isRecord(value) {
2379
2379
  return typeof value === "object" && value !== null && !Array.isArray(value);
@@ -1,6 +1,6 @@
1
1
  import {
2
2
  getFarmRouteLabel
3
- } from "./chunk-XYCB3CXM.mjs";
3
+ } from "./chunk-IEXZMDF4.mjs";
4
4
  import {
5
5
  _classifyFarmMCPClient,
6
6
  _farmMCPClientSession,
@@ -32,7 +32,7 @@ import {
32
32
  import {
33
33
  collectFarmNativeServerFns,
34
34
  findFarmNativeScreenFiles
35
- } from "./chunk-L2KGQXFU.mjs";
35
+ } from "./chunk-GKDOKES3.mjs";
36
36
  import {
37
37
  assertFarmDocsAdapterServesNoGuardedPages,
38
38
  compileFarmDocsAdapterEdgeManifest,
@@ -41,7 +41,7 @@ import {
41
41
  listFarmDocsAdapterPages,
42
42
  listFarmDocsAdapterRoutes,
43
43
  listFarmDocsPagePaths
44
- } from "./chunk-HBZQIRRM.mjs";
44
+ } from "./chunk-JCERO6YF.mjs";
45
45
  import {
46
46
  FARM_DOCS_LAST_MODIFIED_MANIFEST,
47
47
  createFarmDocsHandler,
@@ -71,7 +71,7 @@ import {
71
71
  getDeployTargetForPreset,
72
72
  hasCustomFarmRouteContext,
73
73
  resolveDeployOutputPath
74
- } from "./chunk-H6MYRZ2U.mjs";
74
+ } from "./chunk-JL2HNLMC.mjs";
75
75
  import {
76
76
  resolveFarmInstrumentationFile
77
77
  } from "./chunk-QRNYSISP.mjs";
@@ -117,14 +117,14 @@ import {
117
117
  resolveFarmNotFoundComponentPath,
118
118
  resolveFarmRouteRootStrategy,
119
119
  toBakedMarkdownSourcePath
120
- } from "./chunk-D5GFVHBV.mjs";
120
+ } from "./chunk-MEXGQE4T.mjs";
121
121
  import {
122
122
  TAILWIND_CSS_BROWSER_TARGET,
123
123
  generateFarmClientPluginEntryCode,
124
124
  hasFarmServerRuntimePlugins,
125
125
  includesTailwindVitePlugin,
126
126
  loadTailwindVitePlugin
127
- } from "./chunk-V36K4TSU.mjs";
127
+ } from "./chunk-ADKPJZPP.mjs";
128
128
  import {
129
129
  PluginManager
130
130
  } from "./chunk-6IKUYFNQ.mjs";
@@ -137,7 +137,7 @@ import {
137
137
  import {
138
138
  FARM_PRERENDER_ENV,
139
139
  _farmWebMCPReportsEnabled
140
- } from "./chunk-SIJ3DREB.mjs";
140
+ } from "./chunk-ST3U7XVO.mjs";
141
141
  import {
142
142
  HOISTED_HEAD_ELEMENT,
143
143
  appMiddlewareMayHandlePath,
@@ -165,7 +165,7 @@ import {
165
165
  listFarmBuiltInRoutePaths,
166
166
  resolveFarmApiCatalogInput,
167
167
  resolveFarmAppManifestInput
168
- } from "./chunk-XYCB3CXM.mjs";
168
+ } from "./chunk-IEXZMDF4.mjs";
169
169
  import {
170
170
  FARM_DEFAULT_MCP_PATH,
171
171
  createFarmDefaultMCPServer,
@@ -173,7 +173,7 @@ import {
173
173
  } from "./chunk-WABOJXAA.mjs";
174
174
  import {
175
175
  isFarmPreviewDeploymentEnvironment
176
- } from "./chunk-RCJAOQWW.mjs";
176
+ } from "./chunk-NPR6SCEV.mjs";
177
177
  import {
178
178
  FARM_NATIVE_SERVER_FN_PLUGIN
179
179
  } from "./chunk-L4RTTTVE.mjs";
@@ -194,7 +194,7 @@ import {
194
194
  withFarmSourceSnapshot,
195
195
  withFarmSourceSnapshotOf,
196
196
  withPackageClientBoundaryCache
197
- } from "./chunk-E7ISZK3R.mjs";
197
+ } from "./chunk-ZVT2F3JU.mjs";
198
198
  import {
199
199
  generateFarmDocsAdapterClientRuntime,
200
200
  getFarmDocsAdapterConfigModule
@@ -320,7 +320,7 @@ import {
320
320
  } from "./chunk-2I6PUKWJ.mjs";
321
321
  import {
322
322
  FARM_VERSION
323
- } from "./chunk-BOHBFBRA.mjs";
323
+ } from "./chunk-6VMBLDWY.mjs";
324
324
  import {
325
325
  FARM_VIDEO_PLAYER_PATH
326
326
  } from "./chunk-23NBOP43.mjs";
@@ -6,6 +6,9 @@ import {
6
6
  resolvePlatformBlock,
7
7
  resolvePlatformProfile
8
8
  } from "./chunk-UB7RVEMX.mjs";
9
+ import {
10
+ FARM_DESKTOP_PERMISSIONS
11
+ } from "./chunk-G7LNCHTS.mjs";
9
12
 
10
13
  // src/desktop/config.ts
11
14
  import { existsSync } from "fs";
@@ -21,8 +24,9 @@ function resolveFarmPlatform(env = process.env) {
21
24
  const value = env[FARM_PLATFORM_ENV];
22
25
  return value === "desktop" || value === "mobile" ? value : "web";
23
26
  }
24
- var DESKTOP_KEYS = /* @__PURE__ */ new Set(["name", "id", "version", "icon", "window", "shell"]);
27
+ var DESKTOP_KEYS = /* @__PURE__ */ new Set(["name", "id", "version", "icon", "window", "permissions", "shell"]);
25
28
  var WINDOW_KEYS = /* @__PURE__ */ new Set(["width", "height", "title", "hideOnClose"]);
29
+ var PERMISSION_KEYS = new Set(FARM_DESKTOP_PERMISSIONS);
26
30
  var APP_ID = /^[A-Za-z][A-Za-z0-9-]*(?:\.[A-Za-z0-9][A-Za-z0-9-]*)+$/;
27
31
  var SHELL_NAME = /^[a-z][a-z0-9-]*$/;
28
32
  var SHELL_PACKAGE = /^(?:@[a-z0-9][a-z0-9._-]*\/)?[a-z0-9][a-z0-9._-]*(?:\/[a-z0-9][a-z0-9._-]*)*$/;
@@ -70,6 +74,20 @@ function validateFarmDesktopConfig(input, context) {
70
74
  fail("window.hideOnClose must be true or false.");
71
75
  }
72
76
  }
77
+ if (input.permissions !== void 0) {
78
+ if (!isPlainObject(input.permissions)) {
79
+ fail('permissions must be an object, such as { microphone: "Notes records voice memos." }.');
80
+ }
81
+ checkKeys(input.permissions, PERMISSION_KEYS, "permissions.");
82
+ for (const key of PERMISSION_KEYS) {
83
+ const value = input.permissions[key];
84
+ if (value !== void 0 && (typeof value !== "string" || !value.trim())) {
85
+ fail(
86
+ `permissions.${key} must be the sentence macOS shows when it asks for access, such as "Notes records voice memos.", or left out for no access.`
87
+ );
88
+ }
89
+ }
90
+ }
73
91
  const shell = optionalString(input.shell, "shell");
74
92
  if (shell !== void 0 && !SHELL_NAME.test(shell) && !shell.includes("/")) {
75
93
  fail(`shell must be an adapter name such as "electrobun" or a package name, got "${shell}".`);
@@ -94,6 +112,11 @@ function resolveFarmDesktopConfig(input, root, context) {
94
112
  const icon = config.icon ? path.resolve(root, config.icon.trim()) : void 0;
95
113
  if (icon && !existsSync(icon))
96
114
  desktopChecker(context).fail(`icon ${config.icon} was not found in ${root}.`);
115
+ const permissions = {};
116
+ for (const key of FARM_DESKTOP_PERMISSIONS) {
117
+ const sentence = config.permissions?.[key]?.trim();
118
+ if (sentence) permissions[key] = sentence;
119
+ }
97
120
  return {
98
121
  name,
99
122
  id: config.id?.trim() || `local.farm.${slug(name)}`,
@@ -105,6 +128,7 @@ function resolveFarmDesktopConfig(input, root, context) {
105
128
  title: config.window?.title?.trim() || name,
106
129
  hideOnClose: config.window?.hideOnClose === true
107
130
  },
131
+ ...Object.keys(permissions).length ? { permissions } : {},
108
132
  shell,
109
133
  shellPackage: resolveFarmDesktopShellPackage(shell)
110
134
  };
@@ -1,6 +1,6 @@
1
1
  "use strict";Object.defineProperty(exports, "__esModule", {value: true}); function _interopRequireWildcard(obj) { if (obj && obj.__esModule) { return obj; } else { var newObj = {}; if (obj != null) { for (var key in obj) { if (Object.prototype.hasOwnProperty.call(obj, key)) { newObj[key] = obj[key]; } } } newObj.default = obj; return newObj; } } function _interopRequireDefault(obj) { return obj && obj.__esModule ? obj : { default: obj }; } 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 _chunkYQXLBYY2cjs = require('./chunk-YQXLBYY2.cjs');
3
+ var _chunk5B2Y4EVScjs = require('./chunk-5B2Y4EVS.cjs');
4
4
 
5
5
 
6
6
  var _chunkN4AM7Q34cjs = require('./chunk-N4AM7Q34.cjs');
@@ -62,7 +62,7 @@ function resolveFarmClientPlugins(plugins, _root) {
62
62
  ];
63
63
  });
64
64
  }
65
- function generateFarmClientPluginEntryCode(plugins, root, srcDir = "src", appPublicData, platform = _chunkYQXLBYY2cjs.resolveFarmPlatform.call(void 0, )) {
65
+ function generateFarmClientPluginEntryCode(plugins, root, srcDir = "src", appPublicData, platform = _chunk5B2Y4EVScjs.resolveFarmPlatform.call(void 0, )) {
66
66
  const resolved = resolveFarmClientPlugins(plugins, root);
67
67
  const appClientEntry = root ? resolveFarmAppClientEntry(root, srcDir) : void 0;
68
68
  const appImport = appClientEntry ? `import farmAppClientDefinition from ${JSON.stringify(appClientEntry.replace(/\\/g, "/"))};` : "";