@farm.js/core 0.1.87 → 0.2.0-beta.1
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/analyzer-IIWSUXSQ.cjs +17 -0
- package/dist/{analyzer-W4EB7DHL.mjs → analyzer-RYSF2BM3.mjs} +2 -2
- package/dist/api/route-manager.cjs +3 -3
- package/dist/api/route-manager.mjs +2 -2
- package/dist/api.cjs +4 -4
- package/dist/api.mjs +3 -3
- package/dist/{app.d-b3A4cca5.d.ts → app.d-CoY-zsJt.d.ts} +1 -1
- package/dist/{app.d-AVZXCfcO.d.mts → app.d-DE5KNbmf.d.mts} +1 -1
- package/dist/{chunk-B7L24VPX.cjs → chunk-22KXTL3I.cjs} +6 -4
- package/dist/{chunk-4SJ22WTT.mjs → chunk-23BZ7ZH6.mjs} +1 -1
- package/dist/{chunk-33WR5XV5.cjs → chunk-27ESPHQA.cjs} +4 -4
- package/dist/{chunk-FULX5RYX.cjs → chunk-2OR5WAD5.cjs} +19 -13
- package/dist/{chunk-3F55K4MC.mjs → chunk-2U2GRXP5.mjs} +1 -1
- package/dist/{chunk-K5FLQJW5.mjs → chunk-4A6A6P4T.mjs} +6 -4
- package/dist/chunk-65LZRVCZ.mjs +18 -0
- package/dist/{chunk-XFUPWRKT.cjs → chunk-6BMAGVDI.cjs} +4 -4
- package/dist/{chunk-VCZ4EM5K.cjs → chunk-6ETHVRFO.cjs} +143 -136
- package/dist/{chunk-LBJOHMTB.mjs → chunk-AMMFRXFW.mjs} +1 -1
- package/dist/{chunk-HQ2VAJLW.mjs → chunk-ANKMAGFJ.mjs} +1 -1
- package/dist/{chunk-EZYNIADW.mjs → chunk-CIQCJ72N.mjs} +45 -29
- package/dist/{chunk-A2PPQ5LB.mjs → chunk-CPMK7EFR.mjs} +1 -1
- package/dist/{chunk-B5QRNCIE.mjs → chunk-DATICPTO.mjs} +1 -1
- package/dist/{chunk-QLRI2BX5.mjs → chunk-DZC2XGK4.mjs} +24 -18
- package/dist/{chunk-O7K4HMAQ.mjs → chunk-EBKYRP2P.mjs} +1 -1
- package/dist/{chunk-IM422XKU.cjs → chunk-FJGA3XWL.cjs} +2 -2
- package/dist/{chunk-FLMALEY2.mjs → chunk-GGD57DJA.mjs} +3 -25
- package/dist/chunk-GTHBWZUK.mjs +17 -0
- package/dist/{chunk-CXHVRHM2.cjs → chunk-HENPVGZC.cjs} +2 -2
- package/dist/{chunk-N3VMHPIY.mjs → chunk-HZY63K5C.mjs} +2 -2
- package/dist/{chunk-5D73SKF3.mjs → chunk-ISSFWEPY.mjs} +1 -1
- package/dist/chunk-JIGWHFA5.mjs +32 -0
- package/dist/{chunk-YBXIVQCE.cjs → chunk-JP5TWUK2.cjs} +4 -4
- package/dist/{chunk-TI4BZV6M.cjs → chunk-KBIM7PFQ.cjs} +73 -67
- package/dist/{chunk-UGD53SNO.cjs → chunk-KQ6TYQU7.cjs} +16 -12
- package/dist/{chunk-XMVZXZ32.cjs → chunk-KRU3XPOW.cjs} +2 -2
- package/dist/{chunk-SDNYULFS.cjs → chunk-L4B7PB3H.cjs} +157 -141
- package/dist/{chunk-7BNVUIGL.cjs → chunk-M3JYBZO2.cjs} +2 -2
- package/dist/{chunk-VCI776NG.cjs → chunk-N2ZMSSPP.cjs} +12 -10
- package/dist/{chunk-2UYYXSUS.mjs → chunk-N5NRXLCX.mjs} +4 -2
- package/dist/{chunk-ZCX2XJPY.cjs → chunk-ND65INFS.cjs} +2 -2
- package/dist/{chunk-26HESRBL.mjs → chunk-NVXU5BEG.mjs} +47 -28
- package/dist/{chunk-OBVBII5K.cjs → chunk-NZRAUCUL.cjs} +2 -2
- package/dist/{chunk-U3A46QFD.cjs → chunk-OIPPISQ6.cjs} +81 -62
- package/dist/{chunk-6MZSTPD2.mjs → chunk-OQOII62L.mjs} +1 -1
- package/dist/{chunk-2PJVEL56.cjs → chunk-PCAEJNQF.cjs} +5 -27
- package/dist/{chunk-Q73LRKLP.mjs → chunk-PKV3JGMS.mjs} +1 -1
- package/dist/{chunk-3AV4DCXY.mjs → chunk-PWTBXYJY.mjs} +12 -6
- package/dist/{chunk-PO5MZIWK.mjs → chunk-QBXS4TNG.mjs} +6 -2
- package/dist/chunk-QZUCVJZJ.cjs +18 -0
- package/dist/chunk-SIECKBNK.cjs +17 -0
- package/dist/{chunk-HFRG2IQS.mjs → chunk-SPKZCFPH.mjs} +5 -4
- package/dist/{chunk-CN2JOTRO.cjs → chunk-THGSPDFD.cjs} +7 -7
- package/dist/{chunk-WSQ3S3NV.cjs → chunk-TWFJJPE7.cjs} +13 -12
- package/dist/{chunk-HYL372GW.cjs → chunk-V3Y3R3JJ.cjs} +1 -1
- package/dist/{chunk-QSDIJ45N.mjs → chunk-VZWAXQME.mjs} +1 -1
- package/dist/{chunk-A4WWKG2B.cjs → chunk-WEZTGM7N.cjs} +2 -2
- package/dist/{chunk-JB4BHRFK.cjs → chunk-WP77JDKI.cjs} +16 -16
- package/dist/{chunk-VPGEYX5Y.mjs → chunk-WX752VMN.mjs} +2 -2
- package/dist/chunk-YIGUFJMR.cjs +32 -0
- package/dist/{chunk-4FGTNYHE.mjs → chunk-YPAOC3FO.mjs} +2 -2
- package/dist/{chunk-LIWVPE72.mjs → chunk-Z7ZRBCAB.mjs} +23 -16
- package/dist/{chunk-RGYS5OPL.cjs → chunk-ZPQY7O64.cjs} +3 -3
- package/dist/client.cjs +8 -6
- package/dist/client.d.mts +5 -5
- package/dist/client.d.ts +5 -5
- package/dist/client.mjs +7 -5
- package/dist/{devtools-GWJZPWIW.mjs → devtools-5DBTT2DI.mjs} +1 -1
- package/dist/{devtools-GPIKZ5AV.cjs → devtools-JTJA2KIZ.cjs} +2 -2
- package/dist/docs.cjs +3 -3
- package/dist/docs.mjs +2 -2
- package/dist/environment/vite.cjs +3 -3
- package/dist/environment/vite.mjs +2 -2
- package/dist/i18n/client.cjs +11 -10
- package/dist/i18n/client.mjs +3 -2
- package/dist/index.cjs +30 -28
- package/dist/index.d.mts +5 -5
- package/dist/index.d.ts +5 -5
- package/dist/index.mjs +25 -23
- package/dist/internal/build-runtime.cjs +17 -17
- package/dist/internal/build-runtime.mjs +16 -16
- package/dist/internal/cli-runtime.cjs +5 -5
- package/dist/internal/cli-runtime.mjs +4 -4
- package/dist/internal/client-error-overlay.cjs +4 -4
- package/dist/internal/client-error-overlay.mjs +1 -1
- package/dist/internal/client-runtime.cjs +11 -12
- package/dist/internal/client-runtime.d.mts +6 -4
- package/dist/internal/client-runtime.d.ts +6 -4
- package/dist/internal/client-runtime.mjs +11 -12
- package/dist/internal/config-runtime.cjs +3 -3
- package/dist/internal/config-runtime.mjs +2 -2
- package/dist/internal/infra-analytics-runtime.cjs +6 -6
- package/dist/internal/infra-analytics-runtime.mjs +4 -4
- package/dist/internal/islands-boot.cjs +20 -15
- package/dist/internal/islands-boot.mjs +6 -1
- package/dist/internal/native-server-fns.cjs +4 -4
- package/dist/internal/native-server-fns.mjs +3 -3
- package/dist/internal/product-telemetry-runtime.cjs +3 -3
- package/dist/internal/product-telemetry-runtime.mjs +2 -2
- package/dist/internal/production-runtime.cjs +4 -4
- package/dist/internal/production-runtime.mjs +3 -3
- package/dist/internal/spa-router.cjs +4 -3
- package/dist/internal/spa-router.d.mts +1 -1
- package/dist/internal/spa-router.d.ts +1 -1
- package/dist/internal/spa-router.mjs +3 -2
- package/dist/{manager-PX4QN4HK.cjs → manager-37UJPUN4.cjs} +4 -4
- package/dist/{manager-OMTC5FOJ.mjs → manager-7BNSJKME.mjs} +3 -3
- package/dist/{navigation-delegate.d-ChfinbWB.d.mts → navigation-delegate.d-B9GjWbov.d.mts} +1 -1
- package/dist/{navigation-delegate.d-fMgELdAe.d.ts → navigation-delegate.d-BbW1_pf_.d.ts} +1 -1
- package/dist/navigation.cjs +6 -5
- package/dist/navigation.d.mts +2 -2
- package/dist/navigation.d.ts +2 -2
- package/dist/navigation.mjs +5 -4
- package/dist/plugin.cjs +12 -12
- package/dist/plugin.mjs +11 -11
- package/dist/query/client.cjs +8 -7
- package/dist/query/client.mjs +3 -2
- package/dist/renderer-client.cjs +14 -13
- package/dist/renderer-client.d.mts +3 -3
- package/dist/renderer-client.d.ts +3 -3
- package/dist/renderer-client.mjs +5 -4
- package/dist/{router.d-D5Mp7bpO.d.ts → router.d-Bm9FNSu3.d.ts} +1 -1
- package/dist/{router.d-DrQ1QDFk.d.mts → router.d-YKVirmj4.d.mts} +1 -1
- package/dist/{rsc-pipeline-TQOSDWOU.cjs → rsc-pipeline-LGXJGGMW.cjs} +3 -3
- package/dist/{rsc-pipeline-KLMQU3YP.mjs → rsc-pipeline-W5DSWDHD.mjs} +2 -2
- package/dist/{runtime-BDPBO65S.mjs → runtime-UOZKSM5S.mjs} +2 -2
- package/dist/{runtime-CQSCRVZ7.cjs → runtime-YV4X5FAK.cjs} +4 -4
- package/dist/server.cjs +48 -33
- package/dist/server.d.mts +1 -1
- package/dist/server.d.ts +1 -1
- package/dist/server.mjs +28 -13
- package/dist/{spa-router.d-CXgvy-7L.d.mts → spa-router.d-DGmropfK.d.mts} +3 -1
- package/dist/{spa-router.d-BXxoU3Cv.d.ts → spa-router.d-nE1jHNGt.d.ts} +3 -1
- package/dist/{store-core.d-D00BsbnO.d.ts → store-core.d-B5cwOd8g.d.ts} +2 -2
- package/dist/{store-core.d-CDbVAbTn.d.mts → store-core.d-C-gATBwd.d.mts} +2 -2
- package/dist/testing.cjs +2 -2
- package/dist/testing.mjs +2 -2
- package/dist/version.cjs +2 -2
- package/dist/version.mjs +1 -1
- package/dist/vite.cjs +12 -12
- package/dist/vite.mjs +11 -11
- package/package.json +3 -3
- package/dist/analyzer-LLU2Z6I4.cjs +0 -17
- package/dist/chunk-SBDWCDS6.cjs +0 -8
- package/dist/chunk-YX6AFPXC.mjs +0 -8
- /package/dist/{chunk-MZR22RAC.cjs → chunk-FLKG2PYH.cjs} +0 -0
- /package/dist/{chunk-ALOFMAFA.mjs → chunk-OOOUYA6L.mjs} +0 -0
|
@@ -6,7 +6,8 @@ var _chunkVWIW47FWcjs = require('./chunk-VWIW47FW.cjs');
|
|
|
6
6
|
var _chunkHS4JPIGRcjs = require('./chunk-HS4JPIGR.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
|
-
|
|
9
|
+
|
|
10
|
+
var _chunkSIECKBNKcjs = require('./chunk-SIECKBNK.cjs');
|
|
10
11
|
|
|
11
12
|
|
|
12
13
|
var _chunkSXXSQVKKcjs = require('./chunk-SXXSQVKK.cjs');
|
|
@@ -137,7 +138,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
137
138
|
/**
|
|
138
139
|
* Recursively find all route.ts files
|
|
139
140
|
*/
|
|
140
|
-
findRouteFiles(dir) {
|
|
141
|
+
findRouteFiles(dir, polyroute = _chunkSIECKBNKcjs.hasPolyroutePlugin.call(void 0, _optionalChain([this, 'access', _ => _.viteServer, 'optionalAccess', _2 => _2.config, 'optionalAccess', _3 => _3.plugins]))) {
|
|
141
142
|
const files = [];
|
|
142
143
|
if (!fs.existsSync(dir)) {
|
|
143
144
|
return files;
|
|
@@ -146,8 +147,8 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
146
147
|
for (const entry of entries) {
|
|
147
148
|
const fullPath = path.join(dir, entry.name);
|
|
148
149
|
if (entry.isDirectory()) {
|
|
149
|
-
files.push(...this.findRouteFiles(fullPath));
|
|
150
|
-
} else if (
|
|
150
|
+
files.push(...this.findRouteFiles(fullPath, polyroute));
|
|
151
|
+
} else if (_chunkSIECKBNKcjs.isFarmAPIRouteFileName.call(void 0, entry.name, polyroute)) {
|
|
151
152
|
files.push(fullPath);
|
|
152
153
|
}
|
|
153
154
|
}
|
|
@@ -175,7 +176,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
175
176
|
if (existingSources) {
|
|
176
177
|
for (const method of availableMethods) {
|
|
177
178
|
const existingSource = existingSources.get(method);
|
|
178
|
-
if (_optionalChain([existingSource, 'optionalAccess',
|
|
179
|
+
if (_optionalChain([existingSource, 'optionalAccess', _4 => _4.appDir]) === appDir) {
|
|
179
180
|
throw new APIRouteConflictError(routePath, method, existingSource.filePath, filePath);
|
|
180
181
|
}
|
|
181
182
|
}
|
|
@@ -191,7 +192,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
191
192
|
this.registerRouteShape(routePath, filePath, appDir);
|
|
192
193
|
const existingRoute = this.routes.get(routePath);
|
|
193
194
|
const mergedMethods = existingRoute ? [...existingRoute.methods] : [];
|
|
194
|
-
const openapi = { ..._optionalChain([existingRoute, 'optionalAccess',
|
|
195
|
+
const openapi = { ..._optionalChain([existingRoute, 'optionalAccess', _5 => _5.openapi]) };
|
|
195
196
|
for (const method of availableMethods) {
|
|
196
197
|
if (!mergedMethods.includes(method)) mergedMethods.push(method);
|
|
197
198
|
if (routeOpenAPI) openapi[method] = routeOpenAPI;
|
|
@@ -202,7 +203,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
202
203
|
path: routePath,
|
|
203
204
|
filePath,
|
|
204
205
|
methods: mergedMethods,
|
|
205
|
-
endpoints: { ..._optionalChain([existingRoute, 'optionalAccess',
|
|
206
|
+
endpoints: { ..._optionalChain([existingRoute, 'optionalAccess', _6 => _6.endpoints]), ...endpoints },
|
|
206
207
|
openapi: Object.keys(openapi).length > 0 ? openapi : void 0,
|
|
207
208
|
...runtimeConfig
|
|
208
209
|
});
|
|
@@ -228,7 +229,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
228
229
|
const routesModule = await this.loadModule(routesFile);
|
|
229
230
|
for (const exportValue of Object.values(routesModule)) {
|
|
230
231
|
const endpoint = exportValue;
|
|
231
|
-
if (!_optionalChain([endpoint, 'optionalAccess',
|
|
232
|
+
if (!_optionalChain([endpoint, 'optionalAccess', _7 => _7.__path])) {
|
|
232
233
|
continue;
|
|
233
234
|
}
|
|
234
235
|
const method = String(endpoint.__method || "GET").toUpperCase();
|
|
@@ -299,8 +300,8 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
299
300
|
addEndpoint(routePath, filePath, method, endpoint, appDir, runtimeConfig = {}) {
|
|
300
301
|
const normalizedMethod = method.toUpperCase();
|
|
301
302
|
const existingRoute = this.routes.get(routePath);
|
|
302
|
-
const existingSource = _optionalChain([this, 'access',
|
|
303
|
-
if (_optionalChain([existingSource, 'optionalAccess',
|
|
303
|
+
const existingSource = _optionalChain([this, 'access', _8 => _8.endpointSources, 'access', _9 => _9.get, 'call', _10 => _10(routePath), 'optionalAccess', _11 => _11.get, 'call', _12 => _12(normalizedMethod)]);
|
|
304
|
+
if (_optionalChain([existingSource, 'optionalAccess', _13 => _13.appDir]) === appDir) {
|
|
304
305
|
throw new APIRouteConflictError(
|
|
305
306
|
routePath,
|
|
306
307
|
normalizedMethod,
|
|
@@ -313,7 +314,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
313
314
|
existingRoute.methods.push(normalizedMethod);
|
|
314
315
|
}
|
|
315
316
|
existingRoute.endpoints[normalizedMethod] = endpoint;
|
|
316
|
-
_optionalChainDelete([existingRoute, 'access',
|
|
317
|
+
_optionalChainDelete([existingRoute, 'access', _14 => _14.openapi, 'optionalAccess', _15 => delete _15[normalizedMethod]]);
|
|
317
318
|
Object.assign(existingRoute, runtimeConfig);
|
|
318
319
|
const sources = _nullishCoalesce(this.endpointSources.get(routePath), () => ( /* @__PURE__ */ new Map()));
|
|
319
320
|
sources.set(normalizedMethod, { appDir, filePath });
|
|
@@ -383,7 +384,7 @@ var APIRouteManager = class _APIRouteManager {
|
|
|
383
384
|
return _chunkJYQ6DGPWcjs.createFarmInternalServerErrorResponse.call(void 0, );
|
|
384
385
|
}
|
|
385
386
|
};
|
|
386
|
-
return _optionalChain([this, 'access',
|
|
387
|
+
return _optionalChain([this, 'access', _16 => _16.i18n, 'optionalAccess', _17 => _17.config, 'access', _18 => _18.enabled]) ? _chunkSXXSQVKKcjs._runWithFarmI18nRequest.call(void 0, this.i18n, request, invoke, {
|
|
387
388
|
redirect: false
|
|
388
389
|
}) : invoke();
|
|
389
390
|
};
|
|
@@ -3,7 +3,7 @@
|
|
|
3
3
|
var _chunkAQIRXBBYcjs = require('./chunk-AQIRXBBY.cjs');
|
|
4
4
|
|
|
5
5
|
|
|
6
|
-
var
|
|
6
|
+
var _chunkSIECKBNKcjs = require('./chunk-SIECKBNK.cjs');
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
var _chunkGCJ4GNMCcjs = require('./chunk-GCJ4GNMC.cjs');
|
|
@@ -87,7 +87,7 @@ var APITypeGenerator = class {
|
|
|
87
87
|
if (item.isDirectory()) {
|
|
88
88
|
const newBasePath = basePath ? `${basePath}/${item.name}` : item.name;
|
|
89
89
|
this.scanDirectory(fullPath, appDir, routes, newBasePath);
|
|
90
|
-
} else if (
|
|
90
|
+
} else if (_chunkSIECKBNKcjs.isFarmAPIRouteFileName.call(void 0, item.name)) {
|
|
91
91
|
const routeInfo = this.extractRouteInfo(fullPath, appDir, basePath);
|
|
92
92
|
if (routeInfo) {
|
|
93
93
|
routes.push(routeInfo);
|
|
@@ -7,14 +7,14 @@ var _chunkO4JYMU5Ncjs = require('./chunk-O4JYMU5N.cjs');
|
|
|
7
7
|
|
|
8
8
|
|
|
9
9
|
|
|
10
|
-
var
|
|
10
|
+
var _chunkKQ6TYQU7cjs = require('./chunk-KQ6TYQU7.cjs');
|
|
11
11
|
|
|
12
12
|
|
|
13
13
|
|
|
14
14
|
var _chunkJIBEFLQ7cjs = require('./chunk-JIBEFLQ7.cjs');
|
|
15
15
|
|
|
16
16
|
|
|
17
|
-
var
|
|
17
|
+
var _chunkPCAEJNQFcjs = require('./chunk-PCAEJNQF.cjs');
|
|
18
18
|
|
|
19
19
|
|
|
20
20
|
var _chunkGYJT2U7Jcjs = require('./chunk-GYJT2U7J.cjs');
|
|
@@ -52,7 +52,7 @@ function shouldBlockUnload(options) {
|
|
|
52
52
|
function navigateViaRouter(href, basePath, replace, options = {}) {
|
|
53
53
|
if (typeof window === "undefined") return;
|
|
54
54
|
const url = _chunkD22BUQKWcjs.applyFarmBasePath.call(void 0, href, basePath);
|
|
55
|
-
const spaRouter =
|
|
55
|
+
const spaRouter = _chunkKQ6TYQU7cjs.getInstalledFarmSPARouter.call(void 0, );
|
|
56
56
|
if (spaRouter) {
|
|
57
57
|
void spaRouter.navigate(url, {
|
|
58
58
|
replace,
|
|
@@ -72,7 +72,7 @@ function writeHistory(url, replace) {
|
|
|
72
72
|
} else {
|
|
73
73
|
window.history.pushState(null, "", url);
|
|
74
74
|
}
|
|
75
|
-
|
|
75
|
+
_chunkKQ6TYQU7cjs.notifyHistoryChange.call(void 0, "url-search");
|
|
76
76
|
}
|
|
77
77
|
async function writeHistoryUnlessDelegated(url, replace) {
|
|
78
78
|
const target = new URL(url, window.location.href);
|
|
@@ -105,7 +105,7 @@ function useRouter(options = {}) {
|
|
|
105
105
|
setState(readRouterState(basePath, routeMatcher));
|
|
106
106
|
};
|
|
107
107
|
handlePopState();
|
|
108
|
-
const unsubscribe =
|
|
108
|
+
const unsubscribe = _chunkKQ6TYQU7cjs.subscribeHistoryChange.call(void 0, handlePopState);
|
|
109
109
|
return unsubscribe;
|
|
110
110
|
}, [basePath, routeMatcher]);
|
|
111
111
|
const push = (href, navigateOptions) => {
|
|
@@ -116,11 +116,11 @@ function useRouter(options = {}) {
|
|
|
116
116
|
};
|
|
117
117
|
const pushState = (pageState, href) => {
|
|
118
118
|
if (typeof window === "undefined") return;
|
|
119
|
-
|
|
119
|
+
_chunkKQ6TYQU7cjs.getRouter.call(void 0, ).pushState(pageState, resolveClientHref(href, basePath));
|
|
120
120
|
};
|
|
121
121
|
const replaceState = (pageState, href) => {
|
|
122
122
|
if (typeof window === "undefined") return;
|
|
123
|
-
|
|
123
|
+
_chunkKQ6TYQU7cjs.getRouter.call(void 0, ).replaceState(pageState, resolveClientHref(href, basePath));
|
|
124
124
|
};
|
|
125
125
|
const back = () => {
|
|
126
126
|
if (typeof window !== "undefined") {
|
|
@@ -143,24 +143,24 @@ function useRouter(options = {}) {
|
|
|
143
143
|
};
|
|
144
144
|
}
|
|
145
145
|
function usePageState() {
|
|
146
|
-
const [state, setState] = _react.useState.call(void 0, () =>
|
|
146
|
+
const [state, setState] = _react.useState.call(void 0, () => _chunkKQ6TYQU7cjs.readPageState.call(void 0, ));
|
|
147
147
|
_react.useEffect.call(void 0, () => {
|
|
148
148
|
if (typeof window === "undefined") return;
|
|
149
149
|
const handlePopState = () => {
|
|
150
|
-
setState(
|
|
150
|
+
setState(_chunkKQ6TYQU7cjs.readPageState.call(void 0, ));
|
|
151
151
|
};
|
|
152
152
|
handlePopState();
|
|
153
|
-
return
|
|
153
|
+
return _chunkKQ6TYQU7cjs.subscribeHistoryChange.call(void 0, handlePopState);
|
|
154
154
|
}, []);
|
|
155
155
|
return state;
|
|
156
156
|
}
|
|
157
157
|
function useNavigation() {
|
|
158
158
|
const [state, setState] = _react.useState.call(void 0,
|
|
159
|
-
() =>
|
|
159
|
+
() => _chunkKQ6TYQU7cjs.getRouter.call(void 0, ).getNavigationState()
|
|
160
160
|
);
|
|
161
161
|
_react.useEffect.call(void 0, () => {
|
|
162
162
|
if (typeof window === "undefined") return;
|
|
163
|
-
return
|
|
163
|
+
return _chunkKQ6TYQU7cjs.getRouter.call(void 0, ).subscribeNavigation(setState);
|
|
164
164
|
}, []);
|
|
165
165
|
return state;
|
|
166
166
|
}
|
|
@@ -172,7 +172,7 @@ function useBlocker(options) {
|
|
|
172
172
|
if (typeof window === "undefined" || !active) {
|
|
173
173
|
return;
|
|
174
174
|
}
|
|
175
|
-
return
|
|
175
|
+
return _chunkKQ6TYQU7cjs.getRouter.call(void 0, ).addBlocker(
|
|
176
176
|
async (context) => {
|
|
177
177
|
const current = optionsRef.current;
|
|
178
178
|
const when = typeof current.when === "function" ? current.when(context) : current.when;
|
|
@@ -195,7 +195,7 @@ function useScrollRestoration(key) {
|
|
|
195
195
|
_react.useEffect.call(void 0, () => {
|
|
196
196
|
const element = ref.current;
|
|
197
197
|
if (!element) return;
|
|
198
|
-
return
|
|
198
|
+
return _chunkKQ6TYQU7cjs.getRouter.call(void 0, ).registerScrollElement(key, element);
|
|
199
199
|
}, [key]);
|
|
200
200
|
return ref;
|
|
201
201
|
}
|
|
@@ -210,13 +210,13 @@ function readRouterState(basePath, routeMatcher) {
|
|
|
210
210
|
};
|
|
211
211
|
}
|
|
212
212
|
const pathname = normalizeClientPathname(url.pathname, basePath);
|
|
213
|
-
const i18n =
|
|
213
|
+
const i18n = _chunkPCAEJNQFcjs.getFarmI18nClientState.call(void 0, );
|
|
214
214
|
const routePathname = i18n ? _chunkGYJT2U7Jcjs.stripFarmLocaleFromPathname.call(void 0, pathname, { ...i18n, basePath: "/" }) : pathname;
|
|
215
215
|
return {
|
|
216
216
|
pathname,
|
|
217
217
|
searchParams: url.searchParams,
|
|
218
218
|
params: _optionalChain([routeMatcher, 'optionalAccess', _5 => _5.match, 'call', _6 => _6(routePathname), 'optionalAccess', _7 => _7.params]) || {},
|
|
219
|
-
pageState: typeof window === "undefined" ? null :
|
|
219
|
+
pageState: typeof window === "undefined" ? null : _chunkKQ6TYQU7cjs.readPageState.call(void 0, )
|
|
220
220
|
};
|
|
221
221
|
}
|
|
222
222
|
function readCurrentUrl() {
|
|
@@ -7,14 +7,14 @@ import {
|
|
|
7
7
|
notifyHistoryChange,
|
|
8
8
|
readPageState,
|
|
9
9
|
subscribeHistoryChange
|
|
10
|
-
} from "./chunk-
|
|
10
|
+
} from "./chunk-QBXS4TNG.mjs";
|
|
11
11
|
import {
|
|
12
12
|
hasFarmNavigationDelegates,
|
|
13
13
|
runFarmNavigationDelegates
|
|
14
14
|
} from "./chunk-RSEAX5MW.mjs";
|
|
15
15
|
import {
|
|
16
16
|
getFarmI18nClientState
|
|
17
|
-
} from "./chunk-
|
|
17
|
+
} from "./chunk-GGD57DJA.mjs";
|
|
18
18
|
import {
|
|
19
19
|
stripFarmLocaleFromPathname
|
|
20
20
|
} from "./chunk-4QBFYEDC.mjs";
|
|
@@ -0,0 +1,32 @@
|
|
|
1
|
+
"use strict";Object.defineProperty(exports, "__esModule", {value: true});// src/client/navigation-url.ts
|
|
2
|
+
var FARM_NAVIGATION_PROTOCOLS = /* @__PURE__ */ new Set(["http:", "https:", "mailto:", "tel:"]);
|
|
3
|
+
function isFarmBlockedNavigationURL(url) {
|
|
4
|
+
if (FARM_NAVIGATION_PROTOCOLS.has(url.protocol)) return false;
|
|
5
|
+
console.error(`[Farm.js] Blocked navigation to a ${url.protocol} URL as a security precaution.`);
|
|
6
|
+
return true;
|
|
7
|
+
}
|
|
8
|
+
function isFarmScriptURL(href) {
|
|
9
|
+
try {
|
|
10
|
+
return new URL(href, "http://farm.invalid").protocol === "javascript:";
|
|
11
|
+
} catch (e) {
|
|
12
|
+
return false;
|
|
13
|
+
}
|
|
14
|
+
}
|
|
15
|
+
function isFarmSameDocumentFragment(href, currentHref) {
|
|
16
|
+
const fragment = href.indexOf("#");
|
|
17
|
+
return fragment >= 0 && href.slice(0, fragment) === currentHref.split("#", 1)[0];
|
|
18
|
+
}
|
|
19
|
+
function isFarmExternalNavigationURL(url, currentOrigin) {
|
|
20
|
+
return url.protocol !== "http:" && url.protocol !== "https:" || url.origin !== currentOrigin;
|
|
21
|
+
}
|
|
22
|
+
function resolveFarmNavigationURL(href, documentUrl) {
|
|
23
|
+
return new URL(href, documentUrl);
|
|
24
|
+
}
|
|
25
|
+
|
|
26
|
+
|
|
27
|
+
|
|
28
|
+
|
|
29
|
+
|
|
30
|
+
|
|
31
|
+
|
|
32
|
+
exports.isFarmBlockedNavigationURL = isFarmBlockedNavigationURL; exports.isFarmScriptURL = isFarmScriptURL; exports.isFarmSameDocumentFragment = isFarmSameDocumentFragment; exports.isFarmExternalNavigationURL = isFarmExternalNavigationURL; exports.resolveFarmNavigationURL = resolveFarmNavigationURL;
|
|
@@ -4,7 +4,7 @@ import {
|
|
|
4
4
|
} from "./chunk-HR4N2K4V.mjs";
|
|
5
5
|
import {
|
|
6
6
|
normalizeFarmProductionSiteOrigin
|
|
7
|
-
} from "./chunk-
|
|
7
|
+
} from "./chunk-PKV3JGMS.mjs";
|
|
8
8
|
import {
|
|
9
9
|
resolveFarmAppManifestConfig
|
|
10
10
|
} from "./chunk-SQ5O7I3L.mjs";
|
|
@@ -29,7 +29,7 @@ import {
|
|
|
29
29
|
} from "./chunk-YT2ZMLXK.mjs";
|
|
30
30
|
import {
|
|
31
31
|
FARM_VERSION
|
|
32
|
-
} from "./chunk-
|
|
32
|
+
} from "./chunk-EBKYRP2P.mjs";
|
|
33
33
|
import {
|
|
34
34
|
applyFarmBasePath
|
|
35
35
|
} from "./chunk-SF3JB56B.mjs";
|
|
@@ -44,7 +44,7 @@ import {
|
|
|
44
44
|
resolveFarmIslxActionsMode,
|
|
45
45
|
resolveFarmRouteRootStrategy,
|
|
46
46
|
toBakedMarkdownSourcePath
|
|
47
|
-
} from "./chunk-
|
|
47
|
+
} from "./chunk-DZC2XGK4.mjs";
|
|
48
48
|
import {
|
|
49
49
|
generateFarmClientPluginEntryCode,
|
|
50
50
|
hasFarmServerRuntimePlugins,
|
|
@@ -59,10 +59,10 @@ import {
|
|
|
59
59
|
import {
|
|
60
60
|
generateFarmTypeArtifacts,
|
|
61
61
|
resolveRouteRenderingConfig
|
|
62
|
-
} from "./chunk-
|
|
62
|
+
} from "./chunk-23BZ7ZH6.mjs";
|
|
63
63
|
import {
|
|
64
64
|
_setFarmInfraAnalyticsWebMCPRoute
|
|
65
|
-
} from "./chunk-
|
|
65
|
+
} from "./chunk-ISSFWEPY.mjs";
|
|
66
66
|
import {
|
|
67
67
|
createFarmRouteRenderPlan,
|
|
68
68
|
farmPathGuardCoversEndpoint,
|
|
@@ -89,13 +89,13 @@ import {
|
|
|
89
89
|
resolveFarmMCPRouteLabel,
|
|
90
90
|
resolveFarmMarkdownRouteLabel,
|
|
91
91
|
setFarmRouteLabel
|
|
92
|
-
} from "./chunk-
|
|
92
|
+
} from "./chunk-YPAOC3FO.mjs";
|
|
93
93
|
import {
|
|
94
94
|
FARM_DEFAULT_MCP_PATH
|
|
95
95
|
} from "./chunk-HR4N2K4V.mjs";
|
|
96
96
|
import {
|
|
97
97
|
isFarmPreviewDeploymentEnvironment
|
|
98
|
-
} from "./chunk-
|
|
98
|
+
} from "./chunk-PKV3JGMS.mjs";
|
|
99
99
|
import {
|
|
100
100
|
createFarmServerFnBoundaryModule,
|
|
101
101
|
isFarmServerFnBoundaryId,
|
|
@@ -146,7 +146,7 @@ import {
|
|
|
146
146
|
usePackageScanCacheFile,
|
|
147
147
|
withFarmSourceSnapshotOf,
|
|
148
148
|
wrapFarmIslandContainers
|
|
149
|
-
} from "./chunk-
|
|
149
|
+
} from "./chunk-NVXU5BEG.mjs";
|
|
150
150
|
import {
|
|
151
151
|
generateFarmDocsAdapterClientRuntime,
|
|
152
152
|
getFarmDocsAdapterConfigModule
|
|
@@ -247,7 +247,11 @@ import {
|
|
|
247
247
|
} from "./chunk-IYEY3JWJ.mjs";
|
|
248
248
|
import {
|
|
249
249
|
APIRouteManager
|
|
250
|
-
} from "./chunk-
|
|
250
|
+
} from "./chunk-SPKZCFPH.mjs";
|
|
251
|
+
import {
|
|
252
|
+
hasPolyroutePlugin,
|
|
253
|
+
isFarmAPIRouteFileName
|
|
254
|
+
} from "./chunk-GTHBWZUK.mjs";
|
|
251
255
|
import {
|
|
252
256
|
getFarmI18nClientSnapshot
|
|
253
257
|
} from "./chunk-O7JEFGUV.mjs";
|
|
@@ -310,7 +314,7 @@ import {
|
|
|
310
314
|
} from "./chunk-EILUVBKS.mjs";
|
|
311
315
|
import {
|
|
312
316
|
FARM_VERSION
|
|
313
|
-
} from "./chunk-
|
|
317
|
+
} from "./chunk-EBKYRP2P.mjs";
|
|
314
318
|
import {
|
|
315
319
|
DEFAULT_FARM_API_BASE_PATH
|
|
316
320
|
} from "./chunk-W6QLRQ3V.mjs";
|
|
@@ -1283,13 +1287,13 @@ function loadFarmDocsSearchDevRuntime() {
|
|
|
1283
1287
|
return import("./search-client-GIXIEU75.mjs");
|
|
1284
1288
|
}
|
|
1285
1289
|
function loadFarmOpenAPIDevRuntime() {
|
|
1286
|
-
return import("./manager-
|
|
1290
|
+
return import("./manager-7BNSJKME.mjs");
|
|
1287
1291
|
}
|
|
1288
1292
|
function loadFarmWorkflowsDevRuntime() {
|
|
1289
1293
|
return import("./workflows.mjs");
|
|
1290
1294
|
}
|
|
1291
1295
|
function loadFarmDevtoolsSnapshotRuntime() {
|
|
1292
|
-
return import("./devtools-
|
|
1296
|
+
return import("./devtools-5DBTT2DI.mjs");
|
|
1293
1297
|
}
|
|
1294
1298
|
function loadFarmDevtoolsUIRuntime() {
|
|
1295
1299
|
return import("./devtools-ui-BOG33MT5.mjs");
|
|
@@ -2635,9 +2639,10 @@ function farmPlugin(options = {}, initialPluginManager, deferredSetup) {
|
|
|
2635
2639
|
const match = /\/(?:page|layout|loading|error)(\.[^./]+)$/.exec(normalized);
|
|
2636
2640
|
return appDirSlugs.some((appDir) => normalized.startsWith(`${appDir}/`)) && !!match && routeModuleExtensions.has(match[1].toLowerCase());
|
|
2637
2641
|
};
|
|
2642
|
+
const polyroute = hasPolyroutePlugin(server.config.plugins);
|
|
2638
2643
|
const isApiRouteFile = (file) => {
|
|
2639
2644
|
const normalized = file.replace(/\\/g, "/");
|
|
2640
|
-
return appDirSlugs.some((appDir) => normalized.startsWith(`${appDir}/api/`)) &&
|
|
2645
|
+
return appDirSlugs.some((appDir) => normalized.startsWith(`${appDir}/api/`)) && isFarmAPIRouteFileName(path6.posix.basename(normalized), polyroute);
|
|
2641
2646
|
};
|
|
2642
2647
|
const isProgrammaticRouteFile = (file) => {
|
|
2643
2648
|
const normalized = file.replace(/\\/g, "/");
|
|
@@ -2699,7 +2704,7 @@ function farmPlugin(options = {}, initialPluginManager, deferredSetup) {
|
|
|
2699
2704
|
if (isI18nCatalogFile(file)) {
|
|
2700
2705
|
farmApp?.getI18nRuntime().reload().then(() => server.ws.send({ type: "full-reload", path: "*" })).catch((error) => logger.warn(`i18n catalog reload failed: ${error.message}`));
|
|
2701
2706
|
}
|
|
2702
|
-
const isRouteRefreshEvent = (ev !== "change" || isStaticMetadataImageFile(file)) && (isAppRuntimeFile(file) || isRendererRouteFile(file) || isProgrammaticRouteFile(file) || isProgrammaticRouteSourceFile(file) && (ev === "unlink" || fileContainsProgrammaticPageRoute(file)));
|
|
2707
|
+
const isRouteRefreshEvent = (ev !== "change" || isStaticMetadataImageFile(file)) && (isAppRuntimeFile(file) || polyroute && isApiRouteFile(file) || isRendererRouteFile(file) || isProgrammaticRouteFile(file) || isProgrammaticRouteSourceFile(file) && (ev === "unlink" || fileContainsProgrammaticPageRoute(file)));
|
|
2703
2708
|
if (isRouteRefreshEvent) {
|
|
2704
2709
|
if (!queuedRouteFiles) {
|
|
2705
2710
|
const files = /* @__PURE__ */ new Set();
|
|
@@ -5430,7 +5435,10 @@ if (import.meta.hot) {
|
|
|
5430
5435
|
)
|
|
5431
5436
|
))
|
|
5432
5437
|
return modules;
|
|
5433
|
-
if (currentFarmConfig &&
|
|
5438
|
+
if (currentFarmConfig && isFarmAPIRouteFileName(
|
|
5439
|
+
path6.posix.basename(normalizedFile),
|
|
5440
|
+
hasPolyroutePlugin(server2.config.plugins)
|
|
5441
|
+
) && getFarmAppDirectories(currentFarmConfig).some(
|
|
5434
5442
|
(appDir) => normalizedFile.startsWith(`${toPosixPath(appDir)}/api/`)
|
|
5435
5443
|
)) {
|
|
5436
5444
|
for (const mod of modules) server2.moduleGraph.invalidateModule(mod);
|
|
@@ -6202,7 +6210,7 @@ import { createClientPluginManager } from '@farm.js/core/plugin/client'
|
|
|
6202
6210
|
// Not @farm.js/core/client: that module's graph imports react, which other renderers' apps lack.
|
|
6203
6211
|
import { SPARouter } from '@farm.js/core/internal/spa-router'
|
|
6204
6212
|
import { isFarmRouteActive } from '@farm.js/core/router'
|
|
6205
|
-
import { installChunkErrorRecovery, installFarmLinkPrefetch, isFarmBlockedNavigationURL, readFarmLinkNavigateOptions, rememberFarmLinkLocale, replayFarmQueuedInteraction, scheduleFarmIslandHydration, createFarmSearchParams, searchParamsToObject, setFarmBasePath, setFarmTrailingSlashPreference, stripFarmBasePath } from '@farm.js/core/internal/client-runtime'
|
|
6213
|
+
import { installChunkErrorRecovery, installFarmLinkPrefetch, isFarmBlockedNavigationURL, readFarmLinkNavigateOptions, targetsCurrentContext, rememberFarmLinkLocale, replayFarmQueuedInteraction, scheduleFarmIslandHydration, createFarmSearchParams, searchParamsToObject, setFarmBasePath, setFarmTrailingSlashPreference, stripFarmBasePath } from '@farm.js/core/internal/client-runtime'
|
|
6206
6214
|
import { reviveDeferredData } from '@farm.js/core/deferred'
|
|
6207
6215
|
import {
|
|
6208
6216
|
createFarmDeploymentMismatchError,
|
|
@@ -8112,8 +8120,7 @@ document.addEventListener('click', function(event) {
|
|
|
8112
8120
|
if (href.startsWith('#')) return;
|
|
8113
8121
|
|
|
8114
8122
|
// Don't intercept if target is set to open in new window
|
|
8115
|
-
|
|
8116
|
-
if (linkTarget && linkTarget !== '_self') return;
|
|
8123
|
+
if (!targetsCurrentContext(target)) return;
|
|
8117
8124
|
|
|
8118
8125
|
// Don't intercept modifier clicks (Ctrl+Click = new tab)
|
|
8119
8126
|
if (isModifierEvent(event)) return;
|
|
@@ -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
|
|
4
|
+
var _chunkM3JYBZO2cjs = require('./chunk-M3JYBZO2.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 =
|
|
67
|
+
const aliases = _chunkM3JYBZO2cjs.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 =
|
|
101
|
+
const resolved = _chunkM3JYBZO2cjs.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;
|
package/dist/client.cjs
CHANGED
|
@@ -13,7 +13,8 @@
|
|
|
13
13
|
|
|
14
14
|
|
|
15
15
|
|
|
16
|
-
var
|
|
16
|
+
var _chunk2OR5WAD5cjs = require('./chunk-2OR5WAD5.cjs');
|
|
17
|
+
require('./chunk-QZUCVJZJ.cjs');
|
|
17
18
|
|
|
18
19
|
|
|
19
20
|
|
|
@@ -30,7 +31,7 @@ var _chunkT7HGXF7Dcjs = require('./chunk-T7HGXF7D.cjs');
|
|
|
30
31
|
|
|
31
32
|
|
|
32
33
|
|
|
33
|
-
var
|
|
34
|
+
var _chunkWP77JDKIcjs = require('./chunk-WP77JDKI.cjs');
|
|
34
35
|
|
|
35
36
|
|
|
36
37
|
var _chunkC7LCTVJ2cjs = require('./chunk-C7LCTVJ2.cjs');
|
|
@@ -51,7 +52,7 @@ var _chunkC7LCTVJ2cjs = require('./chunk-C7LCTVJ2.cjs');
|
|
|
51
52
|
|
|
52
53
|
var _chunkZNXU4E6Acjs = require('./chunk-ZNXU4E6A.cjs');
|
|
53
54
|
require('./chunk-EOXPRC2C.cjs');
|
|
54
|
-
require('./chunk-
|
|
55
|
+
require('./chunk-22KXTL3I.cjs');
|
|
55
56
|
require('./chunk-RK3YYUX6.cjs');
|
|
56
57
|
require('./chunk-N4AQNEXR.cjs');
|
|
57
58
|
|
|
@@ -73,11 +74,12 @@ require('./chunk-O4JYMU5N.cjs');
|
|
|
73
74
|
|
|
74
75
|
|
|
75
76
|
|
|
76
|
-
var
|
|
77
|
+
var _chunkKQ6TYQU7cjs = require('./chunk-KQ6TYQU7.cjs');
|
|
77
78
|
|
|
78
79
|
|
|
79
80
|
var _chunkJIBEFLQ7cjs = require('./chunk-JIBEFLQ7.cjs');
|
|
80
|
-
require('./chunk-
|
|
81
|
+
require('./chunk-PCAEJNQF.cjs');
|
|
82
|
+
require('./chunk-YIGUFJMR.cjs');
|
|
81
83
|
|
|
82
84
|
|
|
83
85
|
|
|
@@ -179,4 +181,4 @@ require('./chunk-UZM3PDKK.cjs');
|
|
|
179
181
|
|
|
180
182
|
|
|
181
183
|
|
|
182
|
-
exports.APIClientError = _chunkZNXU4E6Acjs.APIClientError; exports.FARM_CACHE_INVALIDATION_CHANNEL =
|
|
184
|
+
exports.APIClientError = _chunkZNXU4E6Acjs.APIClientError; exports.FARM_CACHE_INVALIDATION_CHANNEL = _chunk2OR5WAD5cjs.FARM_CACHE_INVALIDATION_CHANNEL; exports.FARM_CLIENT_CACHE_PERSIST_VERSION = _chunk2OR5WAD5cjs.FARM_CLIENT_CACHE_PERSIST_VERSION; exports.FarmClientPluginManager = _chunkOO7DYIJDcjs.FarmClientPluginManager; exports.FetcherInputError = _chunk2OR5WAD5cjs.FetcherInputError; exports.IntegrationClientError = _chunkZNXU4E6Acjs.IntegrationClientError; exports.Link = _chunk2OR5WAD5cjs.Link; exports.SPARouter = _chunkKQ6TYQU7cjs.SPARouter; exports.api = _chunkHA7YRO53cjs.api; exports.clearPersistedCache = _chunk2OR5WAD5cjs.clearPersistedCache; exports.createAPIClient = _chunkZNXU4E6Acjs.createAPIClient; exports.createApiClients = _chunkZNXU4E6Acjs.createApiClients; exports.createClientPluginManager = _chunkOO7DYIJDcjs.createClientPluginManager; exports.createIntegrationApi = _chunkZNXU4E6Acjs.createIntegrationApi; exports.createIntegrationClient = _chunkZNXU4E6Acjs.createIntegrationClient; exports.createIntegrationClients = _chunkZNXU4E6Acjs.createIntegrationClients; exports.createIntegrationServerClient = _chunkZNXU4E6Acjs.createIntegrationServerClient; exports.createIntegrations = _chunkZNXU4E6Acjs.createIntegrations; exports.createServerAPIClient = _chunkZNXU4E6Acjs.createServerAPIClient; exports.createStore = _chunk2OR5WAD5cjs.createStore; exports.defineClientCacheAdapter = _chunk2OR5WAD5cjs.defineClientCacheAdapter; exports.defineIntegrationAPI = _chunkHA7YRO53cjs.defineIntegrationAPI; exports.defineIntegrationAPIOperation = _chunkHA7YRO53cjs.defineIntegrationAPIOperation; exports.delegateNavigation = _chunkJIBEFLQ7cjs.delegateNavigation; exports.enableCrossTabCacheInvalidation = _chunk2OR5WAD5cjs.enableCrossTabCacheInvalidation; exports.enableLiveCacheInvalidation = _chunk2OR5WAD5cjs.enableLiveCacheInvalidation; exports.endpoint = _chunkHA7YRO53cjs.endpoint; exports.fetchServerQuery = _chunkIZYFP7INcjs.fetchServerQuery; exports.getFarmClientDataCache = _chunkI2BYNELAcjs.getFarmClientDataCache; exports.getIntegrationAPIManifest = _chunkZNXU4E6Acjs.getIntegrationAPIManifest; exports.getRouter = _chunkKQ6TYQU7cjs.getRouter; exports.getTheme = _chunkWEGAVN37cjs.getTheme; exports.initConfiguredClientCachePersistence = _chunk2OR5WAD5cjs.initConfiguredClientCachePersistence; exports.initPersistedClientCache = _chunk2OR5WAD5cjs.initPersistedClientCache; exports.installChunkErrorRecovery = _chunkIBEHVSU4cjs.installChunkErrorRecovery; exports.integrationClients = _chunkZNXU4E6Acjs.integrationClients; exports.integrationsClient = _chunkZNXU4E6Acjs.integrationsClient; exports.integrationsServer = _chunkZNXU4E6Acjs.integrationsServer; exports.isChunkLoadError = _chunkIBEHVSU4cjs.isChunkLoadError; exports.navigateTo = _chunkKQ6TYQU7cjs.navigateTo; exports.normalizeFarmClientCacheKey = _chunkI2BYNELAcjs.normalizeFarmClientCacheKey; exports.prefetch = _chunkKQ6TYQU7cjs.prefetch; exports.prefetchServerQuery = _chunkIZYFP7INcjs.prefetchServerQuery; exports.pushState = _chunkKQ6TYQU7cjs.pushState; exports.readPageState = _chunkKQ6TYQU7cjs.readPageState; exports.replaceState = _chunkKQ6TYQU7cjs.replaceState; exports.setTheme = _chunkWEGAVN37cjs.setTheme; exports.storageClientCacheAdapter = _chunk2OR5WAD5cjs.storageClientCacheAdapter; exports.toggleTheme = _chunkWEGAVN37cjs.toggleTheme; exports.useAction = _chunkPZXYAWYGcjs.useAction; exports.useBlocker = _chunkWP77JDKIcjs.useBlocker; exports.useFetcher = _chunk2OR5WAD5cjs.useFetcher; exports.useMutation = _chunk2OR5WAD5cjs.useMutation; exports.useNavigation = _chunkWP77JDKIcjs.useNavigation; exports.usePageState = _chunkWP77JDKIcjs.usePageState; exports.useRouter = _chunkWP77JDKIcjs.useRouter; exports.useScrollRestoration = _chunkWP77JDKIcjs.useScrollRestoration; exports.useServerQuery = _chunkT7HGXF7Dcjs.useServerQuery; exports.useTheme = _chunkC7LCTVJ2cjs.useTheme;
|
package/dist/client.d.mts
CHANGED
|
@@ -6,12 +6,12 @@ export { RouteActionTarget, UseActionFormProps, UseActionReturn, UseServerFnOpti
|
|
|
6
6
|
export { UseServerQueryOptions, UseServerQueryResult, useServerQuery } from './server-query-client.mjs';
|
|
7
7
|
export { a as FarmClientCacheEntry, b as FarmClientCacheKey, F as FarmClientCacheStatus, g as getFarmClientDataCache, n as normalizeFarmClientCacheKey } from './client-cache.d-di_Nasxa.mjs';
|
|
8
8
|
export { F as FarmIntegrationAPI, a as FarmIntegrationAPIBodyFormat, b as FarmIntegrationAPIMethod, c as FarmIntegrationAPIOperation, d as FarmIntegrationAPIResponseFormat, e as api, f as defineIntegrationAPI, g as defineIntegrationAPIOperation, h as endpoint } from './route.d-ShmtqqVQ.mjs';
|
|
9
|
-
import { j as StoreState, l as StoreApi$1, k as StoreValueUpdater, S as StoreKeyListener, D as DefaultRouteHref, F as FarmLinkOptions } from './store-core.d-
|
|
10
|
-
export { a as DefaultRoutePath, b as DefaultRoutePattern, E as ExternalHref, L as LinkDefaultRoute, c as LinkExternalUriSchemes, P as PrefetchBehavior, R as RouteHref, d as RouteOptionalParamValue, e as RouteParamValue, f as RouteParams, g as StoreKeysListener, h as StoreListener, i as StorePatch } from './store-core.d-
|
|
9
|
+
import { j as StoreState, l as StoreApi$1, k as StoreValueUpdater, S as StoreKeyListener, D as DefaultRouteHref, F as FarmLinkOptions } from './store-core.d-C-gATBwd.mjs';
|
|
10
|
+
export { a as DefaultRoutePath, b as DefaultRoutePattern, E as ExternalHref, L as LinkDefaultRoute, c as LinkExternalUriSchemes, P as PrefetchBehavior, R as RouteHref, d as RouteOptionalParamValue, e as RouteParamValue, f as RouteParams, g as StoreKeysListener, h as StoreListener, i as StorePatch } from './store-core.d-C-gATBwd.mjs';
|
|
11
11
|
export { UseThemeResult, useTheme } from './theme/client.mjs';
|
|
12
|
-
export { U as UseBlockerOptions, a as UseBlockerReturn, b as UseRouterOptions, u as useBlocker, c as useNavigation, d as usePageState, e as useRouter, f as useScrollRestoration } from './router.d-
|
|
13
|
-
export { c as FarmNavigateOptions,
|
|
14
|
-
export { F as FarmNavigationDelegate, a as FarmNavigationDelegateContext, d as delegateNavigation } from './navigation-delegate.d-
|
|
12
|
+
export { U as UseBlockerOptions, a as UseBlockerReturn, b as UseRouterOptions, u as useBlocker, c as useNavigation, d as usePageState, e as useRouter, f as useScrollRestoration } from './router.d-YKVirmj4.mjs';
|
|
13
|
+
export { c as FarmNavigateOptions, f as FarmNavigationBlocker, F as FarmNavigationBlockerContext, h as FarmNavigationListener, j as FarmNavigationLocation, a as FarmNavigationState, b as FarmViewTransitionMode, S as SPARouter, k as getRouter, n as navigateTo, p as prefetch, l as pushState, r as readPageState, m as replaceState } from './spa-router.d-DGmropfK.mjs';
|
|
14
|
+
export { F as FarmNavigationDelegate, a as FarmNavigationDelegateContext, d as delegateNavigation } from './navigation-delegate.d-B9GjWbov.mjs';
|
|
15
15
|
export { F as FarmChunkRecoveryOptions, i as installChunkErrorRecovery, a as isChunkLoadError } from './chunk-recovery.d-lnQFzcQP.mjs';
|
|
16
16
|
export { d as FarmClientHydrationCompleteEvent, e as FarmClientHydrationEvent, f as FarmClientHydrationMode, g as FarmClientHydrationSession, h as FarmClientLocation, i as FarmClientNavigationAction, j as FarmClientNavigationErrorEvent, k as FarmClientNavigationEvent, l as FarmClientNavigationLoadedEvent, m as FarmClientNavigationResolvedEvent, a as FarmClientNavigationSession, n as FarmClientPerformanceEvent, b as FarmClientPlugin, o as FarmClientPluginCloseEvent, p as FarmClientPluginEnforce, q as FarmClientPluginErrorEvent, r as FarmClientPluginErrorPhase, F as FarmClientPluginManager, s as FarmClientPluginManagerOptions, t as FarmClientPluginMetadata, u as FarmClientPluginRegistration, v as FarmClientPluginRouter, w as FarmClientPluginSetupEvent, x as FarmClientPluginStateEvent, c as createClientPluginManager } from './lifecycle.d-OtGWAvJT.mjs';
|
|
17
17
|
export { S as ServerQueryFetchOptions, f as fetchServerQuery, p as prefetchServerQuery } from './server-query-runtime.d-CCLGkQtE.mjs';
|
package/dist/client.d.ts
CHANGED
|
@@ -6,12 +6,12 @@ export { RouteActionTarget, UseActionFormProps, UseActionReturn, UseServerFnOpti
|
|
|
6
6
|
export { UseServerQueryOptions, UseServerQueryResult, useServerQuery } from './server-query-client.js';
|
|
7
7
|
export { a as FarmClientCacheEntry, b as FarmClientCacheKey, F as FarmClientCacheStatus, g as getFarmClientDataCache, n as normalizeFarmClientCacheKey } from './client-cache.d-Deoqq-nM.js';
|
|
8
8
|
export { F as FarmIntegrationAPI, a as FarmIntegrationAPIBodyFormat, b as FarmIntegrationAPIMethod, c as FarmIntegrationAPIOperation, d as FarmIntegrationAPIResponseFormat, e as api, f as defineIntegrationAPI, g as defineIntegrationAPIOperation, h as endpoint } from './route.d-Cd4Fi6BA.js';
|
|
9
|
-
import { j as StoreState, l as StoreApi$1, k as StoreValueUpdater, S as StoreKeyListener, D as DefaultRouteHref, F as FarmLinkOptions } from './store-core.d-
|
|
10
|
-
export { a as DefaultRoutePath, b as DefaultRoutePattern, E as ExternalHref, L as LinkDefaultRoute, c as LinkExternalUriSchemes, P as PrefetchBehavior, R as RouteHref, d as RouteOptionalParamValue, e as RouteParamValue, f as RouteParams, g as StoreKeysListener, h as StoreListener, i as StorePatch } from './store-core.d-
|
|
9
|
+
import { j as StoreState, l as StoreApi$1, k as StoreValueUpdater, S as StoreKeyListener, D as DefaultRouteHref, F as FarmLinkOptions } from './store-core.d-B5cwOd8g.js';
|
|
10
|
+
export { a as DefaultRoutePath, b as DefaultRoutePattern, E as ExternalHref, L as LinkDefaultRoute, c as LinkExternalUriSchemes, P as PrefetchBehavior, R as RouteHref, d as RouteOptionalParamValue, e as RouteParamValue, f as RouteParams, g as StoreKeysListener, h as StoreListener, i as StorePatch } from './store-core.d-B5cwOd8g.js';
|
|
11
11
|
export { UseThemeResult, useTheme } from './theme/client.js';
|
|
12
|
-
export { U as UseBlockerOptions, a as UseBlockerReturn, b as UseRouterOptions, u as useBlocker, c as useNavigation, d as usePageState, e as useRouter, f as useScrollRestoration } from './router.d-
|
|
13
|
-
export { c as FarmNavigateOptions,
|
|
14
|
-
export { F as FarmNavigationDelegate, a as FarmNavigationDelegateContext, d as delegateNavigation } from './navigation-delegate.d-
|
|
12
|
+
export { U as UseBlockerOptions, a as UseBlockerReturn, b as UseRouterOptions, u as useBlocker, c as useNavigation, d as usePageState, e as useRouter, f as useScrollRestoration } from './router.d-Bm9FNSu3.js';
|
|
13
|
+
export { c as FarmNavigateOptions, f as FarmNavigationBlocker, F as FarmNavigationBlockerContext, h as FarmNavigationListener, j as FarmNavigationLocation, a as FarmNavigationState, b as FarmViewTransitionMode, S as SPARouter, k as getRouter, n as navigateTo, p as prefetch, l as pushState, r as readPageState, m as replaceState } from './spa-router.d-nE1jHNGt.js';
|
|
14
|
+
export { F as FarmNavigationDelegate, a as FarmNavigationDelegateContext, d as delegateNavigation } from './navigation-delegate.d-BbW1_pf_.js';
|
|
15
15
|
export { F as FarmChunkRecoveryOptions, i as installChunkErrorRecovery, a as isChunkLoadError } from './chunk-recovery.d-lnQFzcQP.js';
|
|
16
16
|
export { d as FarmClientHydrationCompleteEvent, e as FarmClientHydrationEvent, f as FarmClientHydrationMode, g as FarmClientHydrationSession, h as FarmClientLocation, i as FarmClientNavigationAction, j as FarmClientNavigationErrorEvent, k as FarmClientNavigationEvent, l as FarmClientNavigationLoadedEvent, m as FarmClientNavigationResolvedEvent, a as FarmClientNavigationSession, n as FarmClientPerformanceEvent, b as FarmClientPlugin, o as FarmClientPluginCloseEvent, p as FarmClientPluginEnforce, q as FarmClientPluginErrorEvent, r as FarmClientPluginErrorPhase, F as FarmClientPluginManager, s as FarmClientPluginManagerOptions, t as FarmClientPluginMetadata, u as FarmClientPluginRegistration, v as FarmClientPluginRouter, w as FarmClientPluginSetupEvent, x as FarmClientPluginStateEvent, c as createClientPluginManager } from './lifecycle.d-OtGWAvJT.js';
|
|
17
17
|
export { S as ServerQueryFetchOptions, f as fetchServerQuery, p as prefetchServerQuery } from './server-query-runtime.d-BlHd90D0.js';
|
package/dist/client.mjs
CHANGED
|
@@ -13,7 +13,8 @@ import {
|
|
|
13
13
|
storageClientCacheAdapter,
|
|
14
14
|
useFetcher,
|
|
15
15
|
useMutation
|
|
16
|
-
} from "./chunk-
|
|
16
|
+
} from "./chunk-PWTBXYJY.mjs";
|
|
17
|
+
import "./chunk-65LZRVCZ.mjs";
|
|
17
18
|
import {
|
|
18
19
|
installChunkErrorRecovery,
|
|
19
20
|
isChunkLoadError
|
|
@@ -30,7 +31,7 @@ import {
|
|
|
30
31
|
usePageState,
|
|
31
32
|
useRouter,
|
|
32
33
|
useScrollRestoration
|
|
33
|
-
} from "./chunk-
|
|
34
|
+
} from "./chunk-WX752VMN.mjs";
|
|
34
35
|
import {
|
|
35
36
|
useTheme
|
|
36
37
|
} from "./chunk-EFLNOZGH.mjs";
|
|
@@ -51,7 +52,7 @@ import {
|
|
|
51
52
|
integrationsServer
|
|
52
53
|
} from "./chunk-7DBJ2SWK.mjs";
|
|
53
54
|
import "./chunk-IAPTECEB.mjs";
|
|
54
|
-
import "./chunk-
|
|
55
|
+
import "./chunk-N5NRXLCX.mjs";
|
|
55
56
|
import "./chunk-5XD2ULJG.mjs";
|
|
56
57
|
import "./chunk-Z64V4WZI.mjs";
|
|
57
58
|
import {
|
|
@@ -73,11 +74,12 @@ import {
|
|
|
73
74
|
pushState,
|
|
74
75
|
readPageState,
|
|
75
76
|
replaceState
|
|
76
|
-
} from "./chunk-
|
|
77
|
+
} from "./chunk-QBXS4TNG.mjs";
|
|
77
78
|
import {
|
|
78
79
|
delegateNavigation
|
|
79
80
|
} from "./chunk-RSEAX5MW.mjs";
|
|
80
|
-
import "./chunk-
|
|
81
|
+
import "./chunk-GGD57DJA.mjs";
|
|
82
|
+
import "./chunk-JIGWHFA5.mjs";
|
|
81
83
|
import {
|
|
82
84
|
getFarmClientDataCache,
|
|
83
85
|
normalizeFarmClientCacheKey
|