@farm.js/core 0.1.65 → 0.1.67
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.
- package/dist/{agent-mcp-handler-QLFDDTYN.mjs → agent-mcp-handler-AZ7QW4UP.mjs} +5 -5
- package/dist/{agent-mcp-handler-OXT73ZBY.cjs → agent-mcp-handler-FER4MQDF.cjs} +6 -6
- package/dist/{agent-mcp.d-QD2WZ9BS.d.ts → agent-mcp.d-BFu9xHAi.d.ts} +1 -1
- package/dist/{agent-mcp.d-CO_ABmNK.d.mts → agent-mcp.d-DWyWkTSy.d.mts} +1 -1
- package/dist/agent-runtime.cjs +6 -5
- package/dist/agent-runtime.d.mts +6 -6
- package/dist/agent-runtime.d.ts +6 -6
- package/dist/agent-runtime.mjs +5 -4
- package/dist/analyzer-KVZGVY5Q.cjs +16 -0
- package/dist/{analyzer-PE33SK5W.mjs → analyzer-TTIIXXMQ.mjs} +3 -3
- package/dist/api/client.cjs +12 -2
- package/dist/api/client.d.mts +4 -4
- package/dist/api/client.d.ts +4 -4
- package/dist/api/client.mjs +12 -2
- package/dist/api/client.native.cjs +12 -2
- package/dist/api/client.native.d.mts +5 -5
- package/dist/api/client.native.d.ts +5 -5
- package/dist/api/client.native.mjs +12 -2
- package/dist/api/node.cjs +223 -0
- package/dist/api/node.d.mts +59 -0
- package/dist/api/node.d.ts +59 -0
- package/dist/api/node.mjs +223 -0
- package/dist/api/route-manager.cjs +11 -11
- package/dist/api/route-manager.d.mts +10 -9
- package/dist/api/route-manager.d.ts +10 -9
- package/dist/api/route-manager.mjs +10 -10
- package/dist/api/runtime.cjs +11 -7
- package/dist/api/runtime.d.mts +7 -7
- package/dist/api/runtime.d.ts +7 -7
- package/dist/api/runtime.mjs +10 -6
- package/dist/{api-client.d-BNLXNCXJ.d.mts → api-client.d-Bp35zMqR.d.mts} +1 -1
- package/dist/{api-client.d-ddQBNGtu.d.ts → api-client.d-CFI_xL0V.d.ts} +1 -1
- package/dist/api.cjs +17 -13
- package/dist/api.d.mts +11 -10
- package/dist/api.d.ts +11 -10
- package/dist/api.mjs +16 -12
- package/dist/{app-manifest.d-BpKxiU_E.d.mts → app-manifest.d-CRmjN5j9.d.mts} +1 -1
- package/dist/{app-manifest.d-DDmNkYQQ.d.ts → app-manifest.d-CwfhGrVR.d.ts} +1 -1
- package/dist/app-markdown.cjs +5 -5
- package/dist/app-markdown.d.mts +7 -7
- package/dist/app-markdown.d.ts +7 -7
- package/dist/app-markdown.mjs +4 -4
- package/dist/{app.d-x68Cwr0_.d.ts → app.d-BX9LVTiP.d.ts} +50 -9
- package/dist/{app.d-kuoVWhWM.d.mts → app.d-uBBUxwyV.d.mts} +50 -9
- package/dist/{chunk-V56632LA.cjs → chunk-22IWL4YD.cjs} +19 -5
- package/dist/{chunk-CZF4XIRZ.cjs → chunk-23PVOIPT.cjs} +3 -3
- package/dist/{chunk-5C7XMKQ4.cjs → chunk-2AFW7673.cjs} +6 -1
- package/dist/{chunk-SYW346ZN.cjs → chunk-2LHZD3OP.cjs} +1 -21
- package/dist/{chunk-ZZI56IUY.mjs → chunk-2ZOYOYEE.mjs} +13 -13
- package/dist/{chunk-RVGSVQWT.mjs → chunk-3T5TLFCQ.mjs} +10 -5
- package/dist/{chunk-XBSKPLHF.cjs → chunk-3T7ALZJF.cjs} +2 -2
- package/dist/{chunk-JCEFKP5M.mjs → chunk-423SSBYQ.mjs} +6 -0
- package/dist/{chunk-7QVRWGBL.cjs → chunk-4DRINDGN.cjs} +319 -138
- package/dist/{chunk-O6L3YYPM.cjs → chunk-4E57QHPW.cjs} +8 -16
- package/dist/{chunk-WKPBIT5Q.cjs → chunk-4HGLJOXZ.cjs} +6 -6
- package/dist/{chunk-JGAE5XPL.cjs → chunk-4JX3M4C6.cjs} +2 -1
- package/dist/{chunk-CJNAUEVC.mjs → chunk-4QENVMG7.mjs} +1 -1
- package/dist/{chunk-IMK32ERL.cjs → chunk-556H7JCE.cjs} +65 -48
- package/dist/{chunk-OLIGNTWU.cjs → chunk-5NFQ6AZI.cjs} +7 -7
- package/dist/{chunk-6HRAK7I5.mjs → chunk-5OFNUETM.mjs} +8 -2
- package/dist/{chunk-TZVUF5JJ.mjs → chunk-5TA63JD3.mjs} +4 -4
- package/dist/{chunk-RD623KW4.cjs → chunk-67MZTLTF.cjs} +21 -3
- package/dist/chunk-6I4BFRE7.cjs +51 -0
- package/dist/{chunk-OSFIUSYK.cjs → chunk-6R53ZWX2.cjs} +7 -7
- package/dist/{chunk-MGKW5XZE.cjs → chunk-6SQZXRJ2.cjs} +7 -7
- package/dist/{chunk-WNXVWXG3.cjs → chunk-6V5YWI4W.cjs} +2 -2
- package/dist/{chunk-BM2LH2JM.mjs → chunk-6YBYX4K4.mjs} +13 -12
- package/dist/{chunk-X3XUZWRB.mjs → chunk-724MGMIL.mjs} +17 -3
- package/dist/{chunk-K5EW7GUU.mjs → chunk-7BIW7VCW.mjs} +13 -5
- package/dist/{chunk-HPP2II4Z.mjs → chunk-7PJARAQQ.mjs} +1 -1
- package/dist/{chunk-LEJDW34D.cjs → chunk-7PPLTD3P.cjs} +3 -3
- package/dist/{chunk-TGULJSHD.mjs → chunk-AJNBTOVQ.mjs} +20 -9
- package/dist/{chunk-FBEBSAVI.cjs → chunk-AKIQ54FK.cjs} +82 -63
- package/dist/{chunk-2NGZFOKG.mjs → chunk-AOIUYHPH.mjs} +2 -2
- package/dist/{chunk-ZEXE4TGY.mjs → chunk-AQDLVHNF.mjs} +230 -110
- package/dist/{chunk-NKRZLQUK.mjs → chunk-AQIO3RNL.mjs} +1 -1
- package/dist/chunk-AQIRXBBY.cjs +26 -0
- package/dist/chunk-AZ6IW6SF.mjs +28 -0
- package/dist/{chunk-QMDU6QHN.mjs → chunk-B6RBJJ5G.mjs} +1 -1
- package/dist/{chunk-I32V5CZL.cjs → chunk-BDYM2TN3.cjs} +28 -17
- package/dist/{chunk-JLDNXURZ.cjs → chunk-BZWTBELF.cjs} +32 -32
- package/dist/{chunk-ITV4QQL2.cjs → chunk-C6CUUBY5.cjs} +14 -3
- package/dist/{chunk-V727H3RI.cjs → chunk-CCAUIBIS.cjs} +6 -0
- package/dist/{chunk-YN6BHOYY.cjs → chunk-CL52PD6D.cjs} +10 -3
- package/dist/{chunk-ZX2JHEWW.mjs → chunk-CO3YMZFD.mjs} +20 -9
- package/dist/{chunk-XURDCXNH.cjs → chunk-CSLHNBPS.cjs} +6 -6
- package/dist/{chunk-CNNBFGL5.cjs → chunk-DB2HSHQA.cjs} +14 -14
- package/dist/{chunk-XQSYOVCW.cjs → chunk-DBYNZIIQ.cjs} +13 -5
- package/dist/{chunk-32RPJAAS.cjs → chunk-DCXSIEFE.cjs} +40 -41
- package/dist/{chunk-D4MRNBVF.cjs → chunk-DGOFR7D5.cjs} +2 -2
- package/dist/{chunk-QTD6EMN2.mjs → chunk-DQ2DI3Y7.mjs} +11 -4
- package/dist/chunk-DXZ57EPE.mjs +375 -0
- package/dist/{chunk-SA7MLSP4.mjs → chunk-E3HDJCWF.mjs} +3 -3
- package/dist/{chunk-EFZGB7JC.cjs → chunk-E5UN4OWX.cjs} +1 -0
- package/dist/{chunk-HKNYNSOK.mjs → chunk-E6CD45JK.mjs} +30 -31
- package/dist/{chunk-752XUZIM.cjs → chunk-EGIY4A7V.cjs} +6 -6
- package/dist/chunk-EIVGPQN5.mjs +51 -0
- package/dist/{chunk-KPAJWD3N.mjs → chunk-EYPSKXO4.mjs} +1 -1
- package/dist/{chunk-E552H232.cjs → chunk-F43OG25P.cjs} +1 -1
- package/dist/{chunk-UAQD67HM.mjs → chunk-F7JKVHU2.mjs} +1 -1
- package/dist/{chunk-QISW423S.cjs → chunk-FPBOAG6N.cjs} +2 -2
- package/dist/{chunk-2C5L5RPM.cjs → chunk-FT6KJHS3.cjs} +71 -38
- package/dist/{chunk-ES2LD2YD.mjs → chunk-GCRT6GJG.mjs} +18 -0
- package/dist/{chunk-5OJVKXFV.cjs → chunk-GDM3ZD2O.cjs} +10 -8
- package/dist/{chunk-EMDGXYUD.mjs → chunk-GJ7QVFAG.mjs} +16 -7
- package/dist/{chunk-TGSEVBPO.mjs → chunk-GJEC5S4V.mjs} +11 -0
- package/dist/{chunk-ZAUOOGER.mjs → chunk-GTV2ABO7.mjs} +218 -37
- package/dist/{chunk-72JSHQQQ.mjs → chunk-H37MDCPR.mjs} +1 -1
- package/dist/{chunk-HNAISJFD.cjs → chunk-HDPT6OYE.cjs} +9 -3
- package/dist/{chunk-25T5VXOE.mjs → chunk-HFHJJXSV.mjs} +106 -19
- package/dist/{chunk-ZNH6NR3H.cjs → chunk-HJZZSBVK.cjs} +2 -2
- package/dist/{chunk-A3G5IY2W.cjs → chunk-HM7AGSKU.cjs} +1 -1
- package/dist/{chunk-GL7N5UHF.cjs → chunk-HNVAZGQD.cjs} +20 -9
- package/dist/{chunk-GRBJ7VKH.mjs → chunk-HP2DQGQH.mjs} +1 -1
- package/dist/{chunk-E2TSYUHV.mjs → chunk-HRPTMX5C.mjs} +4 -4
- package/dist/{chunk-K7OZAVOI.mjs → chunk-IFR74W6S.mjs} +46 -13
- package/dist/{chunk-5A77OEIG.cjs → chunk-IHTDLCDJ.cjs} +5 -5
- package/dist/{chunk-VQJHT2ND.mjs → chunk-IRA2CZAY.mjs} +2 -2
- package/dist/{chunk-OYZXVBZP.cjs → chunk-IUKBPBM7.cjs} +2 -1
- package/dist/chunk-J6TZRYCO.cjs +22 -0
- package/dist/{chunk-WYAXRIYP.cjs → chunk-J7JHVCWA.cjs} +8 -8
- package/dist/chunk-JSOCDYER.cjs +375 -0
- package/dist/{chunk-YUW7F6SK.mjs → chunk-JVM3DKZE.mjs} +3 -3
- package/dist/{chunk-UPYIFH2H.cjs → chunk-JWLRBDDC.cjs} +2 -2
- package/dist/{chunk-BQWBHWEW.mjs → chunk-JWSI5WO4.mjs} +1 -1
- package/dist/{chunk-OLGQZRW6.mjs → chunk-JZBU7V4D.mjs} +37 -17
- package/dist/{chunk-ONG4RDW3.mjs → chunk-JZGL2PIH.mjs} +13 -3
- package/dist/chunk-K63OWRY2.mjs +22 -0
- package/dist/{chunk-TUPKMMXT.mjs → chunk-K6HIIWUB.mjs} +1 -1
- package/dist/{chunk-MESQF2JC.mjs → chunk-K6SXMVXO.mjs} +2 -2
- package/dist/{chunk-L2JG337G.cjs → chunk-K6VFYFOY.cjs} +33 -31
- package/dist/{chunk-3CCAICF7.cjs → chunk-KCY52OUQ.cjs} +4 -4
- package/dist/{chunk-EZ34EHQP.mjs → chunk-KI3MU7B5.mjs} +1 -1
- package/dist/{chunk-GHNW564E.mjs → chunk-KSZK34HU.mjs} +30 -10
- package/dist/{chunk-RFKTJTWZ.mjs → chunk-KWFNUODD.mjs} +2 -1
- package/dist/{chunk-ECKQFEX2.mjs → chunk-LENKRGBV.mjs} +8 -6
- package/dist/{chunk-C7DCMGC4.cjs → chunk-LPIZMU7D.cjs} +12 -12
- package/dist/{chunk-HEPJIKKQ.cjs → chunk-MCSRMEQV.cjs} +2 -2
- package/dist/{chunk-DQF3QLOH.mjs → chunk-ME7RVELR.mjs} +3 -2
- package/dist/{chunk-3KJPIO5D.cjs → chunk-N5DQMOAG.cjs} +589 -678
- package/dist/{chunk-O4F3JUST.mjs → chunk-NDDRTFN4.mjs} +4 -0
- package/dist/{chunk-CBOEJ5Z4.cjs → chunk-OB3IFUK6.cjs} +133 -46
- package/dist/{chunk-R62SF5R4.mjs → chunk-OB45EAQL.mjs} +6 -1
- package/dist/{chunk-SYXPWJ7N.cjs → chunk-OFBLGH6V.cjs} +17 -18
- package/dist/{chunk-VQ4NWOWO.mjs → chunk-OGVTUGMU.mjs} +5 -13
- package/dist/{chunk-3UZVPO72.mjs → chunk-OIOPQ25L.mjs} +6 -7
- package/dist/{chunk-2XGBJSDV.cjs → chunk-OO7DYIJD.cjs} +73 -24
- package/dist/{chunk-IP2KHSGF.mjs → chunk-P2NBQ5JI.mjs} +57 -4
- package/dist/{chunk-ZQQK4U66.cjs → chunk-PDFFYZAT.cjs} +72 -19
- package/dist/{chunk-GSVJ3IIF.cjs → chunk-PHCJJJZV.cjs} +2 -2
- package/dist/{chunk-EVMXPJCB.mjs → chunk-PKMUQ7LM.mjs} +2 -1
- package/dist/{chunk-YD4J37RN.cjs → chunk-PL6RTBDE.cjs} +30 -19
- package/dist/{chunk-OAJOQU5J.mjs → chunk-PLJKJJ2H.mjs} +82 -63
- package/dist/{chunk-WMTBBQHY.cjs → chunk-PPX7UOFY.cjs} +271 -151
- package/dist/{chunk-6XQSPIN6.cjs → chunk-PWKAX5MS.cjs} +13 -3
- package/dist/{chunk-7XGWBPQQ.cjs → chunk-Q37INCXG.cjs} +13 -8
- package/dist/{chunk-T4M52BA5.cjs → chunk-Q5UX55YA.cjs} +1457 -612
- package/dist/{chunk-53ZCZ46B.cjs → chunk-QGQP6QKO.cjs} +4 -3
- package/dist/{chunk-TZOGZKI7.cjs → chunk-QITSS4TD.cjs} +1381 -626
- package/dist/{chunk-4ZJ5C7UJ.cjs → chunk-QIXEU2WV.cjs} +19 -10
- package/dist/{chunk-HCGWDRZO.mjs → chunk-QJVW76JG.mjs} +17 -6
- package/dist/{chunk-FJWN7RV4.cjs → chunk-QO43L7Z4.cjs} +38 -8
- package/dist/{chunk-ZIHWAN55.cjs → chunk-RE5E2G5S.cjs} +1 -1
- package/dist/chunk-RWR7SMD7.cjs +50 -0
- package/dist/{chunk-7PTISZSQ.cjs → chunk-S7MWSFFP.cjs} +4 -0
- package/dist/chunk-SD6JGJOM.mjs +50 -0
- package/dist/{chunk-7H4SVNC4.cjs → chunk-SPP3EZTJ.cjs} +46 -26
- package/dist/{chunk-E4RDMG3K.mjs → chunk-TEG6HJVF.mjs} +4 -4
- package/dist/{chunk-WAY6LOQH.mjs → chunk-TEJ67GD2.mjs} +1 -1
- package/dist/{chunk-ZNXTU4YH.mjs → chunk-TM2E623I.mjs} +1 -0
- package/dist/{chunk-IFTGERT3.mjs → chunk-TTXIITYA.mjs} +49 -0
- package/dist/{chunk-ZFWYCVKS.mjs → chunk-TY5KCYDE.mjs} +22 -4
- package/dist/{chunk-W2ZXMMHA.mjs → chunk-UHE5JUKB.mjs} +1 -1
- package/dist/{chunk-6X5NKNBE.mjs → chunk-UHNSY2PQ.mjs} +1304 -459
- package/dist/{chunk-UJ3R2AH2.cjs → chunk-UPOYKX4S.cjs} +5 -5
- package/dist/{chunk-2DLGV2ZG.mjs → chunk-UTUS6JUH.mjs} +1 -21
- package/dist/{chunk-Q75QPLBA.mjs → chunk-V5MQMQ2P.mjs} +1 -1
- package/dist/{chunk-TRIDJQ6A.cjs → chunk-V5RTHYJB.cjs} +30 -10
- package/dist/{chunk-QHRCR44V.mjs → chunk-VK54PDQ6.mjs} +25 -5
- package/dist/{chunk-LQNW3ABP.cjs → chunk-VX2HZGC7.cjs} +14 -14
- package/dist/{chunk-2L54YV25.mjs → chunk-WDD5CTZW.mjs} +49 -32
- package/dist/{chunk-7GYCZRTH.mjs → chunk-WGHY3OL5.mjs} +355 -444
- package/dist/{chunk-A2MN5PQJ.mjs → chunk-WMLSZAKN.mjs} +9 -9
- package/dist/{chunk-3EEET2Q5.cjs → chunk-WUTFJOV7.cjs} +32 -12
- package/dist/chunk-WVQNXXNE.cjs +28 -0
- package/dist/{chunk-Y5TOT5F6.cjs → chunk-X3MHKLCO.cjs} +5 -5
- package/dist/{chunk-Z7P2BTZ3.cjs → chunk-XGTFLG73.cjs} +30 -12
- package/dist/{chunk-VHHLKIDZ.mjs → chunk-XNZWMXCF.mjs} +1090 -335
- package/dist/{chunk-FIR62CR3.mjs → chunk-XUES6OET.mjs} +1 -1
- package/dist/{chunk-XCXHQBMM.mjs → chunk-Y2LU4LE5.mjs} +1 -1
- package/dist/{chunk-5J45H65F.mjs → chunk-Y5LEPEVH.mjs} +1 -1
- package/dist/{chunk-BT4SEFLC.cjs → chunk-YAEN3L2F.cjs} +3 -2
- package/dist/chunk-YFTGIHNC.mjs +26 -0
- package/dist/{chunk-KL7SHLQB.mjs → chunk-YGJ5P3TJ.mjs} +31 -1
- package/dist/{chunk-UYRI6U3P.mjs → chunk-YQYTQJZN.mjs} +3 -2
- package/dist/{chunk-X4K7TYN6.cjs → chunk-YVTS3S3F.cjs} +24 -23
- package/dist/{chunk-72KABRWN.mjs → chunk-ZJGFAW5U.mjs} +5 -3
- package/dist/{chunk-TNBJ4LZG.mjs → chunk-ZPKJPM7K.mjs} +4 -4
- package/dist/client/lifecycle.cjs +2 -2
- package/dist/client/lifecycle.d.mts +1 -1
- package/dist/client/lifecycle.d.ts +1 -1
- package/dist/client/lifecycle.mjs +1 -1
- package/dist/{client-component.d-D74pqdea.d.mts → client-component.d-CDRvRmbU.d.mts} +2 -2
- package/dist/{client-component.d-D8VcypQA.d.ts → client-component.d-DWRKyAp5.d.ts} +2 -2
- package/dist/client-plugins.cjs +2 -2
- package/dist/{client-plugins.d-D4-6hNx7.d.mts → client-plugins.d-BNILjfX3.d.mts} +94 -140
- package/dist/{client-plugins.d-CXElzotB.d.ts → client-plugins.d-CrKZiNSN.d.ts} +94 -140
- package/dist/client-plugins.d.mts +6 -6
- package/dist/client-plugins.d.ts +6 -6
- package/dist/client-plugins.mjs +1 -1
- package/dist/client.cjs +11 -9
- package/dist/client.d.mts +13 -13
- package/dist/client.d.ts +13 -13
- package/dist/client.mjs +10 -8
- package/dist/{config.d-qt-mE8O5.d.mts → config.d-BKIhJtmr.d.mts} +7 -2
- package/dist/{config.d-qt-mE8O5.d.ts → config.d-BKIhJtmr.d.ts} +7 -2
- package/dist/config.d.mts +6 -6
- package/dist/config.d.ts +6 -6
- package/dist/cron.cjs +2 -2
- package/dist/cron.mjs +1 -1
- package/dist/deferred.cjs +2 -2
- package/dist/deferred.mjs +1 -1
- package/dist/deployment.cjs +2 -2
- package/dist/deployment.mjs +1 -1
- package/dist/desktop.d.mts +7 -7
- package/dist/desktop.d.ts +7 -7
- package/dist/{devtools-SGYOG36E.cjs → devtools-RZVT4JVN.cjs} +36 -32
- package/dist/{devtools-PUVZB3F2.mjs → devtools-UFQYT3VA.mjs} +31 -27
- package/dist/docs.cjs +26 -25
- package/dist/docs.d.mts +20 -8
- package/dist/docs.d.ts +20 -8
- package/dist/docs.mjs +25 -24
- package/dist/env-types.cjs +3 -3
- package/dist/env-types.mjs +2 -2
- package/dist/environment/vite.cjs +5 -5
- package/dist/environment/vite.mjs +4 -4
- package/dist/headers.cjs +3 -3
- package/dist/headers.mjs +2 -2
- package/dist/image/server.d.mts +1 -1
- package/dist/image/server.d.ts +1 -1
- package/dist/image/sharp.d.mts +1 -1
- package/dist/image/sharp.d.ts +1 -1
- package/dist/{image-config.d-CeDgNyX4.d.mts → image-config.d-ByhQ0TT7.d.mts} +3 -1
- package/dist/{image-config.d-CeDgNyX4.d.ts → image-config.d-ByhQ0TT7.d.ts} +3 -1
- package/dist/image.cjs +6 -6
- package/dist/image.d.mts +1 -1
- package/dist/image.d.ts +1 -1
- package/dist/image.mjs +1 -1
- package/dist/index.cjs +143 -128
- package/dist/{index.d-SSgYDv4D.d.mts → index.d-Bdm6866n.d.mts} +1 -1
- package/dist/{index.d-A_x10zGS.d.ts → index.d-Dey5T14f.d.ts} +1 -1
- package/dist/index.d.mts +31 -82
- package/dist/index.d.ts +31 -82
- package/dist/index.mjs +214 -199
- package/dist/{integration-orm-52GPGTHO.cjs → integrations/orm.cjs} +5 -5
- package/dist/integrations/orm.d.mts +33 -0
- package/dist/integrations/orm.d.ts +33 -0
- package/dist/{integration-orm-CO23MSFE.mjs → integrations/orm.mjs} +5 -5
- package/dist/integrations.cjs +6 -5
- package/dist/integrations.d.mts +6 -6
- package/dist/integrations.d.ts +6 -6
- package/dist/integrations.mjs +5 -4
- package/dist/internal/app-markdown-runtime.cjs +4 -4
- package/dist/internal/app-markdown-runtime.d.mts +17 -8
- package/dist/internal/app-markdown-runtime.d.ts +17 -8
- package/dist/internal/app-markdown-runtime.mjs +3 -3
- package/dist/internal/build-runtime.cjs +70 -68
- package/dist/internal/build-runtime.d.mts +8 -8
- package/dist/internal/build-runtime.d.ts +8 -8
- package/dist/internal/build-runtime.mjs +69 -67
- package/dist/internal/cli-runtime.cjs +45 -44
- package/dist/internal/cli-runtime.mjs +44 -43
- package/dist/internal/client-error-overlay.cjs +6 -6
- package/dist/internal/client-error-overlay.mjs +2 -2
- package/dist/internal/client-runtime.cjs +60 -6
- package/dist/internal/client-runtime.d.mts +40 -11
- package/dist/internal/client-runtime.d.ts +40 -11
- package/dist/internal/client-runtime.mjs +58 -4
- package/dist/internal/compression-runtime.d.mts +6 -6
- package/dist/internal/compression-runtime.d.ts +6 -6
- package/dist/internal/config-runtime.cjs +25 -24
- package/dist/internal/config-runtime.d.mts +9 -9
- package/dist/internal/config-runtime.d.ts +9 -9
- package/dist/internal/config-runtime.mjs +24 -23
- package/dist/internal/docs-precompiled-runtime.cjs +16 -5
- package/dist/internal/docs-precompiled-runtime.d.mts +7 -0
- package/dist/internal/docs-precompiled-runtime.d.ts +7 -0
- package/dist/internal/docs-precompiled-runtime.mjs +15 -4
- package/dist/internal/infra-analytics-runtime.cjs +11 -11
- package/dist/internal/infra-analytics-runtime.mjs +9 -9
- package/dist/internal/islands-runtime.cjs +33 -4
- package/dist/internal/islands-runtime.d.mts +1 -1
- package/dist/internal/islands-runtime.d.ts +1 -1
- package/dist/internal/islands-runtime.mjs +31 -2
- package/dist/internal/native-server-fns.cjs +6 -6
- package/dist/internal/native-server-fns.mjs +5 -5
- package/dist/internal/product-telemetry-runtime.cjs +3 -3
- package/dist/internal/product-telemetry-runtime.mjs +2 -2
- package/dist/internal/production-runtime.cjs +54 -40
- package/dist/internal/production-runtime.d.mts +23 -15
- package/dist/internal/production-runtime.d.ts +23 -15
- package/dist/internal/production-runtime.mjs +69 -55
- package/dist/internal/react-cache.cjs +3 -3
- package/dist/internal/react-cache.mjs +1 -1
- package/dist/{lifecycle.d-C2aLBOwu.d.ts → lifecycle.d-keQs5Swc.d.mts} +7 -1
- package/dist/{lifecycle.d-C2aLBOwu.d.mts → lifecycle.d-keQs5Swc.d.ts} +7 -1
- package/dist/{manager-H5ZM3HAM.mjs → manager-JIA66YJ2.mjs} +4 -3
- package/dist/manager-JOHU6BQI.cjs +15 -0
- package/dist/markdown.cjs +7 -3
- package/dist/markdown.d.mts +6 -6
- package/dist/markdown.d.ts +6 -6
- package/dist/markdown.mjs +6 -2
- package/dist/middleware.cjs +10 -10
- package/dist/middleware.d.mts +8 -8
- package/dist/middleware.d.ts +8 -8
- package/dist/middleware.mjs +9 -9
- package/dist/mobile.d.mts +4 -4
- package/dist/mobile.d.ts +4 -4
- package/dist/mount.d-BP0nLYQO.d.mts +38 -0
- package/dist/mount.d-CkiPky_F.d.ts +38 -0
- package/dist/{native-server-fn-handler-GLRHAYWV.mjs → native-server-fn-handler-EP5AFJYE.mjs} +5 -5
- package/dist/{native-server-fn-handler-J5MYRXN6.cjs → native-server-fn-handler-QRTXGZA4.cjs} +6 -6
- package/dist/{native-tree-HE2FLS72.cjs → native-tree-W2SSJB3Y.cjs} +5 -5
- package/dist/{native-tree-YF2DSPKM.mjs → native-tree-Y5YQANW7.mjs} +4 -4
- package/dist/{navigation-delegate.d-DQVYKoaZ.d.mts → navigation-delegate.d-CdBP-hkZ.d.mts} +1 -1
- package/dist/{navigation-delegate.d-GghbHJuK.d.ts → navigation-delegate.d-DchcGzAQ.d.ts} +1 -1
- package/dist/navigation.cjs +8 -7
- package/dist/navigation.d.mts +9 -9
- package/dist/navigation.d.ts +9 -9
- package/dist/navigation.mjs +7 -6
- package/dist/{nitro-DD4QCA66.mjs → nitro-55YOZWRA.mjs} +11 -11
- package/dist/{nitro-VRDX2H4M.cjs → nitro-EEX2J3KB.cjs} +13 -13
- package/dist/{plugin-53SY5YBS.mjs → plugin-SAS22JL7.mjs} +4 -3
- package/dist/{plugin-HZIBL3DW.cjs → plugin-WIU4GDD4.cjs} +5 -4
- package/dist/plugin.cjs +61 -59
- package/dist/plugin.d.mts +8 -8
- package/dist/plugin.d.ts +8 -8
- package/dist/plugin.mjs +60 -58
- package/dist/{port-UFUZL6RI.mjs → port-CLL4BC4O.mjs} +1 -1
- package/dist/{port-VTLHPZOI.cjs → port-HASZTQGY.cjs} +9 -9
- package/dist/{production-runtime.d-Bzns3NW9.d.ts → production-runtime.d-Dou_Htas.d.ts} +1 -1
- package/dist/{production-runtime.d-DiFa5vHW.d.mts → production-runtime.d-VwsBzIee.d.mts} +1 -1
- package/dist/query/client.cjs +9 -7
- package/dist/query/client.mjs +5 -3
- package/dist/{render-plan.d-CL_Ikfg_.d.ts → render-plan.d-D8UakAIk.d.ts} +1 -1
- package/dist/{render-plan.d-CcF0MeCf.d.mts → render-plan.d-LKymStDJ.d.mts} +1 -1
- package/dist/renderer/none/server.cjs +35 -0
- package/dist/renderer/none/server.d.mts +21 -0
- package/dist/renderer/none/server.d.ts +21 -0
- package/dist/renderer/none/server.mjs +35 -0
- package/dist/renderer/react/server.cjs +2 -2
- package/dist/renderer/react/server.mjs +3 -3
- package/dist/renderer-client.cjs +8 -6
- package/dist/renderer-client.d.mts +9 -9
- package/dist/renderer-client.d.ts +9 -9
- package/dist/renderer-client.mjs +5 -3
- package/dist/renderer.cjs +6 -2
- package/dist/renderer.d.mts +20 -2
- package/dist/renderer.d.ts +20 -2
- package/dist/renderer.mjs +5 -1
- package/dist/request.cjs +2 -2
- package/dist/{request.d-B1RnTLri.d.ts → request.d-B928QjWy.d.ts} +1 -1
- package/dist/{request.d-DarDOCk9.d.mts → request.d-KG-4d2eG.d.mts} +1 -1
- package/dist/request.d.mts +7 -7
- package/dist/request.d.ts +7 -7
- package/dist/request.mjs +1 -1
- package/dist/{route-rendering.d-BTUYCIj4.d.ts → route-rendering.d-DoEe_w9t.d.ts} +1 -1
- package/dist/{route-rendering.d-D_2Ual0-.d.mts → route-rendering.d-NIHQeb4m.d.mts} +1 -1
- package/dist/{route.d-BaVH3V0w.d.mts → route.d-DrXkpvcg.d.mts} +1 -1
- package/dist/{route.d-DBTEqifW.d.ts → route.d-hs-_cyHn.d.ts} +1 -1
- package/dist/{router.d-Cuv1jntg.d.mts → router.d-B8PkJSGp.d.mts} +1 -1
- package/dist/{router.d-CMANF6da.d.ts → router.d-DYnRHQwz.d.ts} +1 -1
- package/dist/routes.cjs +3 -3
- package/dist/{routes.d-c2HKfrfL.d.mts → routes.d-DgZ_jgGG.d.mts} +1 -1
- package/dist/{routes.d-B6yFe6jm.d.ts → routes.d-uUBZyWoK.d.ts} +1 -1
- package/dist/routes.d.mts +6 -6
- package/dist/routes.d.ts +6 -6
- package/dist/routes.mjs +2 -2
- package/dist/{rsc-pipeline-T3PWURLJ.mjs → rsc-pipeline-4OJ5ZQNZ.mjs} +26 -25
- package/dist/{rsc-pipeline-V4ANLRAA.cjs → rsc-pipeline-7K5H2RPH.cjs} +27 -26
- package/dist/{runtime-LRIQ3XH7.mjs → runtime-U7O3HZOZ.mjs} +62 -36
- package/dist/{runtime-5AROV2C3.cjs → runtime-X52Q7JFR.cjs} +72 -46
- package/dist/{runtime.d-wvh4ngU0.d.mts → runtime.d-BxQIzwfy.d.mts} +11 -3
- package/dist/{runtime.d-C3RQUj6_.d.ts → runtime.d-DP7mEkEF.d.ts} +11 -3
- package/dist/{schema-dev-notice-JMXEQWIQ.mjs → schema-dev-notice-C2JINRZI.mjs} +3 -2
- package/dist/{schema-dev-notice-PLBFDTOF.cjs → schema-dev-notice-X7GG7QVB.cjs} +5 -4
- package/dist/schema.cjs +6 -2
- package/dist/schema.d-Dny9pnrm.d.mts +298 -0
- package/dist/schema.d-Dny9pnrm.d.ts +298 -0
- package/dist/schema.d.mts +1 -115
- package/dist/schema.d.ts +1 -115
- package/dist/schema.mjs +5 -1
- package/dist/server-fn-client.d.mts +2 -2
- package/dist/server-fn-client.d.ts +2 -2
- package/dist/server-fn.cjs +5 -5
- package/dist/server-fn.mjs +4 -4
- package/dist/server-plugins.cjs +7 -7
- package/dist/server-plugins.d.mts +16 -10
- package/dist/server-plugins.d.ts +16 -10
- package/dist/server-plugins.mjs +8 -8
- package/dist/server-query.cjs +6 -6
- package/dist/server-query.mjs +5 -5
- package/dist/server.cjs +160 -120
- package/dist/server.d.mts +20 -14
- package/dist/server.d.ts +20 -14
- package/dist/server.mjs +138 -98
- package/dist/{spa-router.d-WU_qS5gJ.d.mts → spa-router.d-BgHPVMhz.d.mts} +15 -5
- package/dist/{spa-router.d-m8H_Kl_B.d.ts → spa-router.d-DsFDHTsv.d.ts} +15 -5
- package/dist/testing.cjs +17 -17
- package/dist/testing.d.mts +6 -6
- package/dist/testing.d.ts +6 -6
- package/dist/testing.mjs +13 -13
- package/dist/theme/server.cjs +3 -3
- package/dist/theme/server.mjs +2 -2
- package/dist/{utils.d-W9IiEqmW.d.mts → utils.d-BKyKDBR1.d.mts} +1 -1
- package/dist/{utils.d-C9dQD5Zg.d.ts → utils.d-zxAVcf_V.d.ts} +1 -1
- package/dist/version.cjs +2 -2
- package/dist/version.mjs +1 -1
- package/dist/vite.cjs +63 -61
- package/dist/vite.d.mts +32 -12
- package/dist/vite.d.ts +32 -12
- package/dist/vite.mjs +62 -60
- package/dist/workflows.cjs +4 -4
- package/dist/workflows.mjs +3 -3
- package/package.json +31 -1
- package/dist/analyzer-GHWK46LX.cjs +0 -16
- package/dist/chunk-5YPBFMBN.cjs +0 -19
- package/dist/chunk-OM7WILES.mjs +0 -100
- package/dist/chunk-Q5B4LNON.mjs +0 -19
- package/dist/chunk-QPJ4MZTO.mjs +0 -60
- package/dist/chunk-R53QDV6T.cjs +0 -100
- package/dist/chunk-UYTAP4FQ.cjs +0 -60
- package/dist/manager-2LUKNX2N.cjs +0 -14
- /package/dist/{chunk-QGOZLGVP.mjs → chunk-I6FIAWNT.mjs} +0 -0
- /package/dist/{chunk-XPIPMWY3.cjs → chunk-K5NI5YQR.cjs} +0 -0
- /package/dist/{chunk-NWUHS6GV.cjs → chunk-QEJWNXRI.cjs} +0 -0
- /package/dist/{chunk-FSXSQQTV.mjs → chunk-TXE4SAMV.mjs} +0 -0
- /package/dist/{chunk-ZXK2EYQW.cjs → chunk-UUQNJDGH.cjs} +0 -0
- /package/dist/{chunk-46P5KNTE.mjs → chunk-VZBAW44S.mjs} +0 -0
|
@@ -0,0 +1,375 @@
|
|
|
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
|
+
|
|
3
|
+
var _chunkAQLHD6HZcjs = require('./chunk-AQLHD6HZ.cjs');
|
|
4
|
+
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
var _chunkKORZ6PREcjs = require('./chunk-KORZ6PRE.cjs');
|
|
8
|
+
|
|
9
|
+
|
|
10
|
+
var _chunkQMNWKQL4cjs = require('./chunk-QMNWKQL4.cjs');
|
|
11
|
+
|
|
12
|
+
// src/client-plugin-build.ts
|
|
13
|
+
var _fs = require('fs'); var _fs2 = _interopRequireDefault(_fs);
|
|
14
|
+
var _path = require('path'); var _path2 = _interopRequireDefault(_path);
|
|
15
|
+
var CLIENT_KEYS = [
|
|
16
|
+
"public",
|
|
17
|
+
"setup",
|
|
18
|
+
"hydration",
|
|
19
|
+
"navigation",
|
|
20
|
+
"error",
|
|
21
|
+
"performance",
|
|
22
|
+
"close"
|
|
23
|
+
];
|
|
24
|
+
var HYDRATION_KEYS = ["before", "after"];
|
|
25
|
+
var NAVIGATION_KEYS = ["before", "loaded", "resolved", "rendered", "error"];
|
|
26
|
+
var MOBILE_SHELL_CLIENT_IMPORT = 'import { farmMobileShellClient as __farmMobileShellClient } from "@farm.js/core/internal/client-runtime";';
|
|
27
|
+
var MOBILE_SHELL_CLIENT_REGISTRATION = ` {
|
|
28
|
+
name: "farm:mobile-shell",
|
|
29
|
+
enforce: "pre",
|
|
30
|
+
definition: __farmMobileShellClient,
|
|
31
|
+
}`;
|
|
32
|
+
var APP_CLIENT_EXTENSIONS = ["ts", "tsx", "js", "jsx", "mts", "mjs"];
|
|
33
|
+
function resolveFarmAppClientEntry(root = process.cwd(), srcDir = "src") {
|
|
34
|
+
const sourceRoot = _path2.default.resolve(root, srcDir);
|
|
35
|
+
for (const extension of APP_CLIENT_EXTENSIONS) {
|
|
36
|
+
const candidate = _path2.default.join(sourceRoot, `client.${extension}`);
|
|
37
|
+
if (_fs2.default.existsSync(candidate) && _fs2.default.statSync(candidate).isFile()) return candidate;
|
|
38
|
+
}
|
|
39
|
+
return void 0;
|
|
40
|
+
}
|
|
41
|
+
function resolveFarmClientPlugins(plugins, _root) {
|
|
42
|
+
if (!_optionalChain([plugins, 'optionalAccess', _ => _.length])) return [];
|
|
43
|
+
return plugins.flatMap((plugin) => {
|
|
44
|
+
if (!plugin.client) return [];
|
|
45
|
+
assertClientLifecycle(plugin.client, plugin.name);
|
|
46
|
+
assertPublicData(plugin.client.public, plugin.name);
|
|
47
|
+
return [
|
|
48
|
+
{
|
|
49
|
+
name: plugin.name,
|
|
50
|
+
version: plugin.version,
|
|
51
|
+
enforce: plugin.enforce,
|
|
52
|
+
definition: plugin.client,
|
|
53
|
+
publicData: plugin.client.public
|
|
54
|
+
}
|
|
55
|
+
];
|
|
56
|
+
});
|
|
57
|
+
}
|
|
58
|
+
function generateFarmClientPluginEntryCode(plugins, root, srcDir = "src", appPublicData, platform = _chunkAQLHD6HZcjs.resolveFarmPlatform.call(void 0, )) {
|
|
59
|
+
const resolved = resolveFarmClientPlugins(plugins, root);
|
|
60
|
+
const appClientEntry = root ? resolveFarmAppClientEntry(root, srcDir) : void 0;
|
|
61
|
+
const appImport = appClientEntry ? `import farmAppClientDefinition from ${JSON.stringify(appClientEntry.replace(/\\/g, "/"))};` : "";
|
|
62
|
+
const mobileShell = platform === "mobile";
|
|
63
|
+
const imports = mobileShell ? [MOBILE_SHELL_CLIENT_IMPORT, appImport].filter(Boolean).join("\n") : appImport;
|
|
64
|
+
const serializedPlugins = mobileShell ? [MOBILE_SHELL_CLIENT_REGISTRATION] : [];
|
|
65
|
+
serializedPlugins.push(
|
|
66
|
+
...resolved.map(
|
|
67
|
+
(plugin) => ` {
|
|
68
|
+
name: ${JSON.stringify(plugin.name)},
|
|
69
|
+
version: ${serializeOptionalString(plugin.version)},
|
|
70
|
+
enforce: ${serializeOptionalString(plugin.enforce)},
|
|
71
|
+
definition: ${serializeClientLifecycle(plugin.definition, plugin.name)},
|
|
72
|
+
public: ${serializePublicData(plugin.publicData)},
|
|
73
|
+
}`
|
|
74
|
+
)
|
|
75
|
+
);
|
|
76
|
+
if (appClientEntry) {
|
|
77
|
+
assertPublicData(appPublicData, "farm:app-client");
|
|
78
|
+
serializedPlugins.push(` {
|
|
79
|
+
name: "farm:app-client",
|
|
80
|
+
enforce: "post",
|
|
81
|
+
definition: farmAppClientDefinition,
|
|
82
|
+
public: ${serializePublicData(appPublicData)},
|
|
83
|
+
}`);
|
|
84
|
+
}
|
|
85
|
+
const registrations = `[
|
|
86
|
+
${serializedPlugins.join(",\n")}
|
|
87
|
+
]`;
|
|
88
|
+
return { imports, registrations, plugins: resolved, empty: serializedPlugins.length === 0 };
|
|
89
|
+
}
|
|
90
|
+
function assertClientLifecycle(client, pluginName) {
|
|
91
|
+
assertLifecycleObject(client, pluginName, "client", CLIENT_KEYS);
|
|
92
|
+
assertHook(client.setup, pluginName, "client.setup");
|
|
93
|
+
assertHook(client.error, pluginName, "client.error");
|
|
94
|
+
assertHook(client.performance, pluginName, "client.performance");
|
|
95
|
+
assertHook(client.close, pluginName, "client.close");
|
|
96
|
+
if (client.hydration !== void 0) {
|
|
97
|
+
assertLifecycleObject(client.hydration, pluginName, "client.hydration", HYDRATION_KEYS);
|
|
98
|
+
assertHook(client.hydration.before, pluginName, "client.hydration.before");
|
|
99
|
+
assertHook(client.hydration.after, pluginName, "client.hydration.after");
|
|
100
|
+
}
|
|
101
|
+
if (client.navigation !== void 0) {
|
|
102
|
+
assertLifecycleObject(client.navigation, pluginName, "client.navigation", NAVIGATION_KEYS);
|
|
103
|
+
for (const key of NAVIGATION_KEYS) {
|
|
104
|
+
assertHook(client.navigation[key], pluginName, `client.navigation.${key}`);
|
|
105
|
+
}
|
|
106
|
+
}
|
|
107
|
+
}
|
|
108
|
+
function assertLifecycleObject(value, pluginName, location, allowedKeys) {
|
|
109
|
+
if (!value || typeof value !== "object" || Array.isArray(value)) {
|
|
110
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location} must be an object`);
|
|
111
|
+
}
|
|
112
|
+
const prototype = Object.getPrototypeOf(value);
|
|
113
|
+
if (prototype !== Object.prototype && prototype !== null) {
|
|
114
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location} must be a plain object`);
|
|
115
|
+
}
|
|
116
|
+
for (const key of Reflect.ownKeys(value)) {
|
|
117
|
+
if (typeof key === "symbol") {
|
|
118
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location} cannot contain symbol keys`);
|
|
119
|
+
}
|
|
120
|
+
if (!allowedKeys.includes(key)) {
|
|
121
|
+
throw new TypeError(`Client plugin "${pluginName}" has an unknown ${location}.${key} option`);
|
|
122
|
+
}
|
|
123
|
+
const descriptor = Object.getOwnPropertyDescriptor(value, key);
|
|
124
|
+
if (!_optionalChain([descriptor, 'optionalAccess', _2 => _2.enumerable])) {
|
|
125
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location}.${key} must be enumerable`);
|
|
126
|
+
}
|
|
127
|
+
if (!("value" in descriptor)) {
|
|
128
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location}.${key} cannot be an accessor`);
|
|
129
|
+
}
|
|
130
|
+
}
|
|
131
|
+
}
|
|
132
|
+
function assertHook(value, pluginName, location) {
|
|
133
|
+
if (value === void 0) return;
|
|
134
|
+
if (typeof value !== "function") {
|
|
135
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location} must be a function`);
|
|
136
|
+
}
|
|
137
|
+
functionSource(value, pluginName, location);
|
|
138
|
+
}
|
|
139
|
+
function serializeClientLifecycle(definition, pluginName) {
|
|
140
|
+
const fields = [];
|
|
141
|
+
pushHook(fields, "setup", definition.setup, pluginName, "client.setup", 2);
|
|
142
|
+
pushHookGroup(fields, "hydration", definition.hydration, HYDRATION_KEYS, pluginName, 2);
|
|
143
|
+
pushHookGroup(fields, "navigation", definition.navigation, NAVIGATION_KEYS, pluginName, 2);
|
|
144
|
+
pushHook(fields, "error", definition.error, pluginName, "client.error", 2);
|
|
145
|
+
pushHook(fields, "performance", definition.performance, pluginName, "client.performance", 2);
|
|
146
|
+
pushHook(fields, "close", definition.close, pluginName, "client.close", 2);
|
|
147
|
+
return fields.length ? `{
|
|
148
|
+
${fields.join(",\n")}
|
|
149
|
+
}` : "{}";
|
|
150
|
+
}
|
|
151
|
+
function pushHookGroup(fields, groupName, group, keys, pluginName, indent) {
|
|
152
|
+
if (!group) return;
|
|
153
|
+
const hooks = [];
|
|
154
|
+
for (const key of keys) {
|
|
155
|
+
pushHook(hooks, key, group[key], pluginName, `client.${groupName}.${key}`, indent + 2);
|
|
156
|
+
}
|
|
157
|
+
fields.push(
|
|
158
|
+
`${" ".repeat(indent)}${JSON.stringify(groupName)}: {
|
|
159
|
+
${hooks.join(",\n")}
|
|
160
|
+
${" ".repeat(indent)}}`
|
|
161
|
+
);
|
|
162
|
+
}
|
|
163
|
+
function pushHook(fields, key, hook, pluginName, location, indent) {
|
|
164
|
+
if (hook === void 0) return;
|
|
165
|
+
fields.push(
|
|
166
|
+
`${" ".repeat(indent)}${JSON.stringify(key)}: ${functionSource(hook, pluginName, location)}`
|
|
167
|
+
);
|
|
168
|
+
}
|
|
169
|
+
function functionSource(value, pluginName, location) {
|
|
170
|
+
if (typeof value !== "function") {
|
|
171
|
+
throw new TypeError(`Client plugin "${pluginName}" ${location} must be a function`);
|
|
172
|
+
}
|
|
173
|
+
const source = Function.prototype.toString.call(value).trim();
|
|
174
|
+
if (!source || source.includes("[native code]")) {
|
|
175
|
+
throw new TypeError(
|
|
176
|
+
`Client plugin "${pluginName}" ${location} must be authored inline and cannot be native or bound`
|
|
177
|
+
);
|
|
178
|
+
}
|
|
179
|
+
if (/^(?:async\s+)?function(?:\s*\*)?(?:\s+|\()/.test(source)) {
|
|
180
|
+
return `(${source})`;
|
|
181
|
+
}
|
|
182
|
+
if (!/^class\b/.test(source)) {
|
|
183
|
+
if (/^async\s*\(/.test(source) && value.name !== "async") return `(${source})`;
|
|
184
|
+
const method = source.match(/^(async\s+)?(\*\s*)?[$A-Z_a-z][$\w]*\s*(\([\s\S]*)$/);
|
|
185
|
+
if (method) {
|
|
186
|
+
const asyncPrefix = _nullishCoalesce(method[1], () => ( ""));
|
|
187
|
+
const generator = method[2] ? "*" : "";
|
|
188
|
+
return `(${asyncPrefix}function${generator}${method[3]})`;
|
|
189
|
+
}
|
|
190
|
+
if (source.includes("=>")) return `(${source})`;
|
|
191
|
+
}
|
|
192
|
+
throw new TypeError(
|
|
193
|
+
`Client plugin "${pluginName}" ${location} must use a function, method, or arrow function`
|
|
194
|
+
);
|
|
195
|
+
}
|
|
196
|
+
function assertPublicData(value, pluginName) {
|
|
197
|
+
if (value === void 0) return;
|
|
198
|
+
const seen = /* @__PURE__ */ new WeakSet();
|
|
199
|
+
const visit = (current, pathSegments) => {
|
|
200
|
+
if (current === null || typeof current === "string" || typeof current === "boolean") {
|
|
201
|
+
return;
|
|
202
|
+
}
|
|
203
|
+
if (typeof current === "number") {
|
|
204
|
+
if (Number.isFinite(current)) return;
|
|
205
|
+
throwPublicDataError(pluginName, pathSegments, "must be a finite number");
|
|
206
|
+
}
|
|
207
|
+
if (typeof current !== "object") {
|
|
208
|
+
throwPublicDataError(pluginName, pathSegments, `cannot contain ${typeof current} values`);
|
|
209
|
+
}
|
|
210
|
+
if (seen.has(current)) {
|
|
211
|
+
throwPublicDataError(pluginName, pathSegments, "cannot contain circular references");
|
|
212
|
+
}
|
|
213
|
+
seen.add(current);
|
|
214
|
+
if (Array.isArray(current)) {
|
|
215
|
+
for (let index = 0; index < current.length; index += 1) {
|
|
216
|
+
if (!Object.prototype.hasOwnProperty.call(current, index)) {
|
|
217
|
+
throwPublicDataError(
|
|
218
|
+
pluginName,
|
|
219
|
+
[...pathSegments, String(index)],
|
|
220
|
+
"cannot contain sparse array slots"
|
|
221
|
+
);
|
|
222
|
+
}
|
|
223
|
+
visit(current[index], [...pathSegments, String(index)]);
|
|
224
|
+
}
|
|
225
|
+
for (const key of Reflect.ownKeys(current)) {
|
|
226
|
+
if (key === "length" || typeof key === "string" && isArrayIndex(key)) continue;
|
|
227
|
+
throwPublicDataError(
|
|
228
|
+
pluginName,
|
|
229
|
+
pathSegments,
|
|
230
|
+
typeof key === "symbol" ? "cannot contain symbol keys" : `cannot contain non-index array property ${key}`
|
|
231
|
+
);
|
|
232
|
+
}
|
|
233
|
+
seen.delete(current);
|
|
234
|
+
return;
|
|
235
|
+
}
|
|
236
|
+
const prototype = Object.getPrototypeOf(current);
|
|
237
|
+
if (prototype !== Object.prototype && prototype !== null) {
|
|
238
|
+
throwPublicDataError(pluginName, pathSegments, "must contain only plain objects and arrays");
|
|
239
|
+
}
|
|
240
|
+
for (const key of Reflect.ownKeys(current)) {
|
|
241
|
+
if (typeof key === "symbol") {
|
|
242
|
+
throwPublicDataError(pluginName, pathSegments, "cannot contain symbol keys");
|
|
243
|
+
}
|
|
244
|
+
const descriptor = Object.getOwnPropertyDescriptor(current, key);
|
|
245
|
+
if (!_optionalChain([descriptor, 'optionalAccess', _3 => _3.enumerable])) {
|
|
246
|
+
throwPublicDataError(
|
|
247
|
+
pluginName,
|
|
248
|
+
[...pathSegments, key],
|
|
249
|
+
"cannot contain non-enumerable properties"
|
|
250
|
+
);
|
|
251
|
+
}
|
|
252
|
+
if (!("value" in descriptor)) {
|
|
253
|
+
throwPublicDataError(
|
|
254
|
+
pluginName,
|
|
255
|
+
[...pathSegments, key],
|
|
256
|
+
"cannot contain accessor properties"
|
|
257
|
+
);
|
|
258
|
+
}
|
|
259
|
+
visit(descriptor.value, [...pathSegments, key]);
|
|
260
|
+
}
|
|
261
|
+
seen.delete(current);
|
|
262
|
+
};
|
|
263
|
+
visit(value, []);
|
|
264
|
+
}
|
|
265
|
+
function throwPublicDataError(pluginName, pathSegments, message) {
|
|
266
|
+
const location = pathSegments.length ? ` at client.public.${pathSegments.join(".")}` : "";
|
|
267
|
+
throw new TypeError(`Client plugin "${pluginName}"${location} ${message}`);
|
|
268
|
+
}
|
|
269
|
+
function serializePublicData(value) {
|
|
270
|
+
if (value === void 0) return "undefined";
|
|
271
|
+
return `JSON.parse(${JSON.stringify(JSON.stringify(value))})`;
|
|
272
|
+
}
|
|
273
|
+
function serializeOptionalString(value) {
|
|
274
|
+
return value === void 0 ? "undefined" : JSON.stringify(value);
|
|
275
|
+
}
|
|
276
|
+
function isArrayIndex(key) {
|
|
277
|
+
const value = Number(key);
|
|
278
|
+
return Number.isInteger(value) && value >= 0 && value < 4294967295 && String(value) === key;
|
|
279
|
+
}
|
|
280
|
+
|
|
281
|
+
// src/build/tailwind.ts
|
|
282
|
+
|
|
283
|
+
|
|
284
|
+
// src/build/vite-plugin-compat.ts
|
|
285
|
+
function adaptTailwindVitePlugin(pluginOption, builder) {
|
|
286
|
+
if (builder !== "rolldown") return pluginOption;
|
|
287
|
+
return adaptPluginOption(pluginOption);
|
|
288
|
+
}
|
|
289
|
+
function adaptPluginOption(pluginOption) {
|
|
290
|
+
if (Array.isArray(pluginOption)) return pluginOption.map(adaptPluginOption);
|
|
291
|
+
if (!pluginOption || typeof pluginOption !== "object") return pluginOption;
|
|
292
|
+
const plugin = pluginOption;
|
|
293
|
+
if (!_optionalChain([plugin, 'access', _4 => _4.name, 'optionalAccess', _5 => _5.startsWith, 'call', _6 => _6("@tailwindcss/vite:generate:")])) return pluginOption;
|
|
294
|
+
if (isVitePluginHook(plugin.transform)) {
|
|
295
|
+
return {
|
|
296
|
+
...plugin,
|
|
297
|
+
transform: withVite5TransformContext(plugin.transform)
|
|
298
|
+
};
|
|
299
|
+
}
|
|
300
|
+
if (plugin.transform && typeof plugin.transform === "object" && "handler" in plugin.transform && isVitePluginHook(plugin.transform.handler)) {
|
|
301
|
+
return {
|
|
302
|
+
...plugin,
|
|
303
|
+
transform: {
|
|
304
|
+
...plugin.transform,
|
|
305
|
+
handler: withVite5TransformContext(plugin.transform.handler)
|
|
306
|
+
}
|
|
307
|
+
};
|
|
308
|
+
}
|
|
309
|
+
return pluginOption;
|
|
310
|
+
}
|
|
311
|
+
function isVitePluginHook(value) {
|
|
312
|
+
return typeof value === "function";
|
|
313
|
+
}
|
|
314
|
+
function withVite5TransformContext(handler) {
|
|
315
|
+
return function(...args) {
|
|
316
|
+
const context = new Proxy(this, {
|
|
317
|
+
get(target, property, receiver) {
|
|
318
|
+
if (property === "environment") return void 0;
|
|
319
|
+
return Reflect.get(target, property, receiver);
|
|
320
|
+
}
|
|
321
|
+
});
|
|
322
|
+
return handler.apply(context, args);
|
|
323
|
+
};
|
|
324
|
+
}
|
|
325
|
+
|
|
326
|
+
// src/build/tailwind.ts
|
|
327
|
+
var TAILWIND_CSS_IMPORT = /@import\s+["']tailwindcss["']/;
|
|
328
|
+
var TAILWIND_VITE_INSTALL_HINT = _chunkKORZ6PREcjs.formatOptionalPeerInstallHint.call(void 0,
|
|
329
|
+
"@tailwindcss/vite",
|
|
330
|
+
"enable built-in Tailwind CSS support",
|
|
331
|
+
{ dev: true }
|
|
332
|
+
);
|
|
333
|
+
var warnedMissingTailwind = false;
|
|
334
|
+
async function loadTailwindVitePlugin(options = {}, importTailwind = () => import("@tailwindcss/vite")) {
|
|
335
|
+
try {
|
|
336
|
+
const tailwindVite = (await importTailwind()).default;
|
|
337
|
+
const plugin = options.builder ? adaptTailwindVitePlugin(tailwindVite(), options.builder) : tailwindVite();
|
|
338
|
+
if (options.announce) _chunkQMNWKQL4cjs.logger.info("\u{1F4E6} Enabled built-in Tailwind support (@tailwindcss/vite)");
|
|
339
|
+
return plugin;
|
|
340
|
+
} catch (error) {
|
|
341
|
+
if (_chunkKORZ6PREcjs.isMissingPackageError.call(void 0, error, "@tailwindcss/vite")) return createMissingTailwindPlugin();
|
|
342
|
+
_chunkQMNWKQL4cjs.logger.warn(
|
|
343
|
+
`Tailwind plugin auto-enable failed${options.label ? ` ${options.label}` : ""}; continuing without it: ${error.message}`
|
|
344
|
+
);
|
|
345
|
+
return void 0;
|
|
346
|
+
}
|
|
347
|
+
}
|
|
348
|
+
function createMissingTailwindPlugin() {
|
|
349
|
+
let root = process.cwd();
|
|
350
|
+
return {
|
|
351
|
+
name: "farm:tailwind-missing",
|
|
352
|
+
enforce: "pre",
|
|
353
|
+
configResolved(config) {
|
|
354
|
+
root = config.root;
|
|
355
|
+
},
|
|
356
|
+
transform(code, id) {
|
|
357
|
+
if (warnedMissingTailwind || !/\.css(?:\?.*)?$/.test(id) || !TAILWIND_CSS_IMPORT.test(code)) {
|
|
358
|
+
return null;
|
|
359
|
+
}
|
|
360
|
+
warnedMissingTailwind = true;
|
|
361
|
+
const file = _path2.default.relative(root, id.split("?", 1)[0]).replace(/\\/g, "/");
|
|
362
|
+
_chunkQMNWKQL4cjs.logger.warn(
|
|
363
|
+
`${file} imports Tailwind CSS, but @tailwindcss/vite is not installed; continuing without Tailwind. ${TAILWIND_VITE_INSTALL_HINT}`
|
|
364
|
+
);
|
|
365
|
+
return null;
|
|
366
|
+
}
|
|
367
|
+
};
|
|
368
|
+
}
|
|
369
|
+
|
|
370
|
+
|
|
371
|
+
|
|
372
|
+
|
|
373
|
+
|
|
374
|
+
|
|
375
|
+
exports.resolveFarmAppClientEntry = resolveFarmAppClientEntry; exports.resolveFarmClientPlugins = resolveFarmClientPlugins; exports.generateFarmClientPluginEntryCode = generateFarmClientPluginEntryCode; exports.loadTailwindVitePlugin = loadTailwindVitePlugin;
|
|
@@ -1,15 +1,15 @@
|
|
|
1
1
|
import {
|
|
2
2
|
getFarmRouteLabel
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-HRPTMX5C.mjs";
|
|
4
4
|
import {
|
|
5
5
|
classifyFarmAgent
|
|
6
|
-
} from "./chunk-
|
|
6
|
+
} from "./chunk-IFR74W6S.mjs";
|
|
7
7
|
import {
|
|
8
8
|
onFarmEvent
|
|
9
9
|
} from "./chunk-2DA7CLY7.mjs";
|
|
10
10
|
import {
|
|
11
11
|
getCurrentRequestOrNull
|
|
12
|
-
} from "./chunk-
|
|
12
|
+
} from "./chunk-5OFNUETM.mjs";
|
|
13
13
|
|
|
14
14
|
// src/plugins/infra-analytics.ts
|
|
15
15
|
import { AsyncLocalStorage } from "async_hooks";
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var _chunkR5U7OIPIcjs = require('./chunk-R5U7OIPI.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkHDPT6OYEcjs = require('./chunk-HDPT6OYE.cjs');
|
|
7
7
|
|
|
8
8
|
// src/middleware/cookie-header.ts
|
|
9
9
|
function parseMiddlewareCookieHeader(cookieHeader) {
|
|
@@ -50,7 +50,7 @@ function toWebRequest(ctx) {
|
|
|
50
50
|
if (isWebRequest(ctx.request)) {
|
|
51
51
|
return ctx.request;
|
|
52
52
|
}
|
|
53
|
-
return
|
|
53
|
+
return _chunkHDPT6OYEcjs.createWebRequestFromFarmRequest.call(void 0, ctx.request, { origin: ctx.url.origin });
|
|
54
54
|
}
|
|
55
55
|
function createRequestMiddlewareContext(ctx) {
|
|
56
56
|
const context = {
|
|
@@ -1,6 +1,9 @@
|
|
|
1
1
|
import {
|
|
2
2
|
APITypeGenerator
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-7PJARAQQ.mjs";
|
|
4
|
+
import {
|
|
5
|
+
toFileModuleUrl
|
|
6
|
+
} from "./chunk-VHIXGZYH.mjs";
|
|
4
7
|
import {
|
|
5
8
|
__require
|
|
6
9
|
} from "./chunk-Y6FXYEAI.mjs";
|
|
@@ -11,12 +14,14 @@ var zodTypeNameKinds = {
|
|
|
11
14
|
ZodArray: "array",
|
|
12
15
|
ZodBoolean: "boolean",
|
|
13
16
|
ZodDefault: "default",
|
|
17
|
+
ZodEffects: "effects",
|
|
14
18
|
ZodEnum: "enum",
|
|
15
19
|
ZodLiteral: "literal",
|
|
16
20
|
ZodNullable: "nullable",
|
|
17
21
|
ZodNumber: "number",
|
|
18
22
|
ZodObject: "object",
|
|
19
23
|
ZodOptional: "optional",
|
|
24
|
+
ZodPipeline: "pipe",
|
|
20
25
|
ZodRecord: "record",
|
|
21
26
|
ZodString: "string",
|
|
22
27
|
ZodTuple: "tuple",
|
|
@@ -35,6 +40,20 @@ function getZodObjectShape(schema) {
|
|
|
35
40
|
const shape = typeof candidate === "function" ? candidate() : candidate;
|
|
36
41
|
return shape && typeof shape === "object" ? shape : void 0;
|
|
37
42
|
}
|
|
43
|
+
function getZodTransformInput(schema) {
|
|
44
|
+
const kind = getZodKind(schema);
|
|
45
|
+
const definition = schema?._def;
|
|
46
|
+
if (kind === "effects") return definition.schema;
|
|
47
|
+
if (kind !== "pipe") return void 0;
|
|
48
|
+
return getZodKind(definition.in) === "transform" ? definition.out : definition.in;
|
|
49
|
+
}
|
|
50
|
+
function unwrapZodTransforms(schema) {
|
|
51
|
+
let current = schema;
|
|
52
|
+
for (let input = getZodTransformInput(current); input; input = getZodTransformInput(current)) {
|
|
53
|
+
current = input;
|
|
54
|
+
}
|
|
55
|
+
return current;
|
|
56
|
+
}
|
|
38
57
|
function isStandardSchema(schema) {
|
|
39
58
|
return !!schema && typeof schema === "object" && typeof schema["~standard"]?.validate === "function";
|
|
40
59
|
}
|
|
@@ -73,7 +92,7 @@ var OpenAPIGenerator = class {
|
|
|
73
92
|
* which documented every `.default()` field as required.
|
|
74
93
|
*/
|
|
75
94
|
isRequiredField(value) {
|
|
76
|
-
const kind = getZodKind(value);
|
|
95
|
+
const kind = getZodKind(unwrapZodTransforms(value));
|
|
77
96
|
return kind !== "optional" && kind !== "default";
|
|
78
97
|
}
|
|
79
98
|
/**
|
|
@@ -85,6 +104,12 @@ var OpenAPIGenerator = class {
|
|
|
85
104
|
if (!kind) {
|
|
86
105
|
return isStandardSchema(zodType) ? { description: "Schema metadata is unavailable for this Standard Schema validator." } : { description: "Schema metadata is unavailable." };
|
|
87
106
|
}
|
|
107
|
+
const transformInput = getZodTransformInput(zodType);
|
|
108
|
+
if (transformInput) {
|
|
109
|
+
const inputSchema = this.processZodType(transformInput);
|
|
110
|
+
const description = zodType.description;
|
|
111
|
+
return description === void 0 || inputSchema.description !== void 0 ? inputSchema : { ...inputSchema, description };
|
|
112
|
+
}
|
|
88
113
|
if (kind === "optional") {
|
|
89
114
|
return this.processZodType(definition.innerType);
|
|
90
115
|
}
|
|
@@ -377,6 +402,12 @@ var OpenAPIGenerator = class {
|
|
|
377
402
|
schema: { type: "string" }
|
|
378
403
|
}));
|
|
379
404
|
}
|
|
405
|
+
loadRouteModule(filePath) {
|
|
406
|
+
return this.context.loadModule ? this.context.loadModule(filePath) : import(
|
|
407
|
+
/* @vite-ignore */
|
|
408
|
+
toFileModuleUrl(filePath)
|
|
409
|
+
);
|
|
410
|
+
}
|
|
380
411
|
/**
|
|
381
412
|
* Extract request body schema from endpoint
|
|
382
413
|
*/
|
|
@@ -385,11 +416,7 @@ var OpenAPIGenerator = class {
|
|
|
385
416
|
return void 0;
|
|
386
417
|
}
|
|
387
418
|
try {
|
|
388
|
-
const
|
|
389
|
-
const routeModule = await import(
|
|
390
|
-
/* @vite-ignore */
|
|
391
|
-
modulePath
|
|
392
|
-
);
|
|
419
|
+
const routeModule = await this.loadRouteModule(route.filePath);
|
|
393
420
|
const handler = routeModule[method];
|
|
394
421
|
const bodySchema = handler?.__types?.body ?? handler?._type?.body;
|
|
395
422
|
if (bodySchema) {
|
|
@@ -424,14 +451,10 @@ var OpenAPIGenerator = class {
|
|
|
424
451
|
async getParameters(route, method) {
|
|
425
452
|
const parameters = [];
|
|
426
453
|
try {
|
|
427
|
-
const
|
|
428
|
-
const routeModule = await import(
|
|
429
|
-
/* @vite-ignore */
|
|
430
|
-
modulePath
|
|
431
|
-
);
|
|
454
|
+
const routeModule = await this.loadRouteModule(route.filePath);
|
|
432
455
|
const handler = routeModule[method];
|
|
433
456
|
const querySchema = handler?.__types?.query ?? handler?._type?.query;
|
|
434
|
-
const shape = getZodObjectShape(querySchema);
|
|
457
|
+
const shape = getZodObjectShape(unwrapZodTransforms(querySchema));
|
|
435
458
|
if (shape) {
|
|
436
459
|
Object.entries(shape).forEach(([key, value]) => {
|
|
437
460
|
if (getZodKind(value) || isStandardSchema(value)) {
|
|
@@ -482,10 +505,7 @@ var OpenAPIGenerator = class {
|
|
|
482
505
|
}
|
|
483
506
|
async getEndpointOpenAPIMetadata(route, method) {
|
|
484
507
|
try {
|
|
485
|
-
const routeModule = await
|
|
486
|
-
/* @vite-ignore */
|
|
487
|
-
route.filePath
|
|
488
|
-
);
|
|
508
|
+
const routeModule = await this.loadRouteModule(route.filePath);
|
|
489
509
|
return routeModule[method]?.__openapi ?? {};
|
|
490
510
|
} catch {
|
|
491
511
|
return {};
|
|
@@ -5,6 +5,10 @@ import {
|
|
|
5
5
|
localizeFarmHref,
|
|
6
6
|
resolveFarmLocalePath
|
|
7
7
|
} from "./chunk-7S7AAK2D.mjs";
|
|
8
|
+
import {
|
|
9
|
+
applyFarmBasePath,
|
|
10
|
+
stripFarmBasePath
|
|
11
|
+
} from "./chunk-SF3JB56B.mjs";
|
|
8
12
|
import {
|
|
9
13
|
assertBrowserStableRoutePath
|
|
10
14
|
} from "./chunk-AYP2YFVN.mjs";
|
|
@@ -32,8 +36,8 @@ function validateConfigRouteSource(source, field = "Config route source") {
|
|
|
32
36
|
assertBrowserStableRoutePath(source);
|
|
33
37
|
return source;
|
|
34
38
|
}
|
|
35
|
-
function resolveConfigRoutePathname(pathname, i18n) {
|
|
36
|
-
const localizedPathname = i18n?.enabled ? resolveFarmLocalePath(pathname, i18n) : { pathname };
|
|
39
|
+
function resolveConfigRoutePathname(pathname, i18n, basePath) {
|
|
40
|
+
const localizedPathname = i18n?.enabled ? resolveFarmLocalePath(pathname, i18n) : { pathname: basePath ? stripFarmBasePath(pathname, basePath) : pathname };
|
|
37
41
|
return {
|
|
38
42
|
pathname: normalizeConfigRoutePathname(canonicalizeRequestPathname(localizedPathname.pathname)),
|
|
39
43
|
...i18n?.enabled && "locale" in localizedPathname ? { locale: localizedPathname.locale } : {}
|
|
@@ -46,6 +50,10 @@ function normalizeConfigRoutePathname(pathname) {
|
|
|
46
50
|
function localizeConfigRouteDestination(destination, locale, i18n) {
|
|
47
51
|
return locale && i18n?.enabled ? localizeFarmHref(destination, locale, i18n) : destination;
|
|
48
52
|
}
|
|
53
|
+
function resolveConfigRedirectDestination(destination, locale, i18n, basePath) {
|
|
54
|
+
if (locale && i18n?.enabled) return localizeFarmHref(destination, locale, i18n);
|
|
55
|
+
return basePath ? applyFarmBasePath(destination, basePath) : destination;
|
|
56
|
+
}
|
|
49
57
|
function appendCatchAll(pattern) {
|
|
50
58
|
return pattern.endsWith("/") ? `${pattern.slice(0, -1)}(?:/(.*))?` : `${pattern}(.*)`;
|
|
51
59
|
}
|
|
@@ -150,6 +158,8 @@ export {
|
|
|
150
158
|
validateConfigRouteSource,
|
|
151
159
|
resolveConfigRoutePathname,
|
|
152
160
|
localizeConfigRouteDestination,
|
|
161
|
+
resolveConfigRedirectDestination,
|
|
153
162
|
compileConfigRoutePattern,
|
|
154
|
-
interpolateConfigRouteDestination
|
|
163
|
+
interpolateConfigRouteDestination,
|
|
164
|
+
encodeConfigRouteSegment
|
|
155
165
|
};
|
|
@@ -0,0 +1,22 @@
|
|
|
1
|
+
// src/schema-owner.ts
|
|
2
|
+
var FARM_SCHEMA_TABLES = /* @__PURE__ */ Symbol.for("farm.schema-tables");
|
|
3
|
+
function declareSchemaTables(target, declaration) {
|
|
4
|
+
Object.defineProperty(target, FARM_SCHEMA_TABLES, {
|
|
5
|
+
value: declaration,
|
|
6
|
+
enumerable: false,
|
|
7
|
+
configurable: true
|
|
8
|
+
});
|
|
9
|
+
return target;
|
|
10
|
+
}
|
|
11
|
+
function readSchemaTables(candidate) {
|
|
12
|
+
if (!candidate || typeof candidate !== "object" && typeof candidate !== "function") {
|
|
13
|
+
return void 0;
|
|
14
|
+
}
|
|
15
|
+
return candidate[FARM_SCHEMA_TABLES];
|
|
16
|
+
}
|
|
17
|
+
|
|
18
|
+
export {
|
|
19
|
+
FARM_SCHEMA_TABLES,
|
|
20
|
+
declareSchemaTables,
|
|
21
|
+
readSchemaTables
|
|
22
|
+
};
|
|
@@ -1,10 +1,10 @@
|
|
|
1
1
|
import {
|
|
2
2
|
collectFarmLlmsTxtPages
|
|
3
|
-
} from "./chunk-
|
|
3
|
+
} from "./chunk-YGJ5P3TJ.mjs";
|
|
4
4
|
import {
|
|
5
5
|
getFarmMarkdownMirrorPath,
|
|
6
6
|
isFarmMarkdownMirrorExposed
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-IFR74W6S.mjs";
|
|
8
8
|
import {
|
|
9
9
|
_listFarmMCPCatalogs,
|
|
10
10
|
_listFarmRegisteredMCPServers
|