@absolutejs/absolute 0.20.0-beta.5 → 0.20.0-beta.51
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/README.md +205 -0
- package/dist/angular/browser.js +392 -361
- package/dist/angular/browser.js.map +3 -3
- package/dist/angular/components/core/streamingSlotRegistrar.js +7 -7
- package/dist/angular/components/core/streamingSlotRegistry.js +4 -4
- package/dist/angular/index.js +355 -302
- package/dist/angular/index.js.map +5 -5
- package/dist/angular/server.js +109 -58
- package/dist/angular/server.js.map +5 -5
- package/dist/build.js +2261 -1335
- package/dist/build.js.map +16 -12
- package/dist/cli/config/client.js +12 -12
- package/dist/cli/config/server.js +1136 -1090
- package/dist/cli/index.js +8615 -1975
- package/dist/client/index.js +29 -25
- package/dist/client/index.js.map +2 -2
- package/dist/core/streamingSlotRegistrar.js +15 -13
- package/dist/core/streamingSlotRegistrar.js.map +2 -2
- package/dist/core/streamingSlotRegistry.js +11 -9
- package/dist/core/streamingSlotRegistry.js.map +2 -2
- package/dist/dev/client/hmrClient.ts +35 -3
- package/dist/dev/client/hmrTiming.ts +6 -0
- package/dist/dev/client/syncDevtools.ts +237 -0
- package/dist/dev/serverBootstrap.js +28 -0
- package/dist/image-client/imageClient.js +7 -7
- package/dist/index.js +3400 -2126
- package/dist/index.js.map +30 -23
- package/dist/islands/browser.js +11 -9
- package/dist/islands/browser.js.map +2 -2
- package/dist/islands/index.js +39 -35
- package/dist/islands/index.js.map +2 -2
- package/dist/mobile/browser.js +167 -20
- package/dist/mobile/browser.js.map +7 -5
- package/dist/mobile/index.js +8144 -3016
- package/dist/mobile/index.js.map +37 -18
- package/dist/mobile/remoteMacAgentEntry.js +1355 -14
- package/dist/mobile/shellAuth.js +36 -0
- package/dist/mobile/shellBootstrap.js +836 -0
- package/dist/mobile/shellExpoAuth.js +163 -0
- package/dist/mobile/shellExpoDevices.js +77 -0
- package/dist/mobile/shellExpoSync.js +104 -0
- package/dist/mobile/shellSync.js +173 -0
- package/dist/react/browser.js +17 -15
- package/dist/react/browser.js.map +2 -2
- package/dist/react/components/browser/index.js +107 -107
- package/dist/react/components/index.js +118 -116
- package/dist/react/components/index.js.map +2 -2
- package/dist/react/hooks/index.js +11 -9
- package/dist/react/hooks/index.js.map +2 -2
- package/dist/react/index.js +92 -49
- package/dist/react/index.js.map +4 -4
- package/dist/react/jsxDevRuntimeCompat.js +11 -9
- package/dist/react/jsxDevRuntimeCompat.js.map +2 -2
- package/dist/react/jsxRuntimeCompat.js +11 -9
- package/dist/react/jsxRuntimeCompat.js.map +2 -2
- package/dist/react/router/browser.js +9 -7
- package/dist/react/router/browser.js.map +2 -2
- package/dist/react/router/index.js +9 -7
- package/dist/react/router/index.js.map +2 -2
- package/dist/react/server.js +51 -10
- package/dist/react/server.js.map +4 -4
- package/dist/src/build/pwa.d.ts +16 -0
- package/dist/src/cli/config/server.d.ts +1 -1
- package/dist/src/cli/instanceStatus.d.ts +1 -0
- package/dist/src/cli/scripts/dev.d.ts +2 -0
- package/dist/src/core/devBuild.d.ts +1 -0
- package/dist/src/core/prepare.d.ts +376 -0
- package/dist/src/dev/clientManager.d.ts +1 -0
- package/dist/src/dev/devCert.d.ts +6 -4
- package/dist/src/dev/serverEntryCopies.d.ts +3 -0
- package/dist/src/mobile/androidEmulatorController.d.ts +8 -1
- package/dist/src/mobile/androidRelease.d.ts +9 -2
- package/dist/src/mobile/androidTestReport.d.ts +14 -0
- package/dist/src/mobile/androidUpgradeConformance.d.ts +47 -0
- package/dist/src/mobile/androidWebView.d.ts +1 -0
- package/dist/src/mobile/browser.d.ts +1 -0
- package/dist/src/mobile/capacitorBundle.d.ts +11 -0
- package/dist/src/mobile/ciWorkflow.d.ts +26 -0
- package/dist/src/mobile/config.d.ts +4 -1
- package/dist/src/mobile/devDeviceAdapter.d.ts +3 -0
- package/dist/src/mobile/deviceCapabilities.d.ts +48 -0
- package/dist/src/mobile/expoBridge.d.ts +91 -0
- package/dist/src/mobile/expoDevController.d.ts +56 -0
- package/dist/src/mobile/expoProject.d.ts +16 -0
- package/dist/src/mobile/index.d.ts +14 -0
- package/dist/src/mobile/iosDeviceAcceptance.d.ts +32 -0
- package/dist/src/mobile/iosPhysicalDeviceTransport.d.ts +16 -0
- package/dist/src/mobile/iosRelease.d.ts +63 -3
- package/dist/src/mobile/iosSimulatorController.d.ts +20 -2
- package/dist/src/mobile/iosTestReport.d.ts +24 -0
- package/dist/src/mobile/mobileBundleInspection.d.ts +55 -0
- package/dist/src/mobile/mobileInspect.d.ts +136 -0
- package/dist/src/mobile/mobilePreview.d.ts +174 -0
- package/dist/src/mobile/mobilePreviewClient.d.ts +1 -0
- package/dist/src/mobile/nativeAuth.d.ts +6 -0
- package/dist/src/mobile/nativeBackgroundSync.d.ts +4 -0
- package/dist/src/mobile/nativeDeviceCapabilities.d.ts +6 -0
- package/dist/src/mobile/nativeRoute.d.ts +13 -0
- package/dist/src/mobile/nativeTestReport.d.ts +91 -0
- package/dist/src/mobile/pageProtocol.d.ts +2 -0
- package/dist/src/mobile/releaseDoctor.d.ts +23 -1
- package/dist/src/mobile/remoteMacProtocol.d.ts +90 -0
- package/dist/src/mobile/remoteMacWire.d.ts +1 -1
- package/dist/src/mobile/shellAuth.d.ts +8 -1
- package/dist/src/mobile/shellBootstrap.d.ts +14 -2
- package/dist/src/mobile/shellExpoAuth.d.ts +12 -0
- package/dist/src/mobile/shellExpoDevices.d.ts +3 -0
- package/dist/src/mobile/shellExpoSync.d.ts +18 -0
- package/dist/src/mobile/shellHttp.d.ts +2 -0
- package/dist/src/mobile/shellPush.d.ts +11 -0
- package/dist/src/mobile/shellSync.d.ts +46 -1
- package/dist/src/mobile/syncRemediation.d.ts +10 -0
- package/dist/src/mobile/syncSchema.d.ts +9 -0
- package/dist/src/mobile/transport.d.ts +7 -0
- package/dist/src/plugins/hmr.d.ts +3 -0
- package/dist/src/plugins/imageOptimizer.d.ts +1 -1
- package/dist/src/react/hooks/useMediaQuery.d.ts +1 -1
- package/dist/src/utils/imageProcessing.d.ts +3 -0
- package/dist/src/utils/loadConfig.d.ts +1 -0
- package/dist/src/utils/logger.d.ts +1 -0
- package/dist/src/utils/startupBanner.d.ts +1 -0
- package/dist/src/utils/userAgentFunctions.d.ts +1 -1
- package/dist/svelte/browser.js +12 -10
- package/dist/svelte/browser.js.map +2 -2
- package/dist/svelte/index.js +86 -43
- package/dist/svelte/index.js.map +4 -4
- package/dist/svelte/server.js +68 -27
- package/dist/svelte/server.js.map +4 -4
- package/dist/types/build.d.ts +53 -3
- package/dist/types/cli.d.ts +1 -0
- package/dist/types/messages.d.ts +1 -1
- package/dist/vue/browser.js +14 -12
- package/dist/vue/browser.js.map +2 -2
- package/dist/vue/components/Image.js +9 -7
- package/dist/vue/components/Image.js.map +2 -2
- package/dist/vue/components/index.js +11 -9
- package/dist/vue/components/index.js.map +2 -2
- package/dist/vue/index.js +91 -48
- package/dist/vue/index.js.map +4 -4
- package/dist/vue/server.js +53 -12
- package/dist/vue/server.js.map +4 -4
- package/package.json +35 -15
package/dist/angular/server.js
CHANGED
|
@@ -19,12 +19,14 @@ var __toESM = (mod, isNodeMode, target) => {
|
|
|
19
19
|
}
|
|
20
20
|
target = mod != null ? __create(__getProtoOf(mod)) : {};
|
|
21
21
|
const to = isNodeMode || !mod || !mod.__esModule ? __defProp(target, "default", { value: mod, enumerable: true }) : target;
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
22
|
+
if (mod && typeof mod === "object" || typeof mod === "function") {
|
|
23
|
+
for (let key of __getOwnPropNames(mod))
|
|
24
|
+
if (!__hasOwnProp.call(to, key))
|
|
25
|
+
__defProp(to, key, {
|
|
26
|
+
get: __accessProp.bind(mod, key),
|
|
27
|
+
enumerable: true
|
|
28
|
+
});
|
|
29
|
+
}
|
|
28
30
|
if (canCache)
|
|
29
31
|
cache.set(mod, to);
|
|
30
32
|
return to;
|
|
@@ -945,10 +947,10 @@ var init_ssrRender = __esm(() => {
|
|
|
945
947
|
// src/angular/islands.ts
|
|
946
948
|
var exports_islands = {};
|
|
947
949
|
__export(exports_islands, {
|
|
948
|
-
|
|
949
|
-
mountAngularIsland: () => mountAngularIsland,
|
|
950
|
+
getAngularIslandSelector: () => getAngularIslandSelector,
|
|
950
951
|
isAngularComponent: () => isAngularComponent,
|
|
951
|
-
|
|
952
|
+
mountAngularIsland: () => mountAngularIsland,
|
|
953
|
+
renderAngularIslandToHtml: () => renderAngularIslandToHtml
|
|
952
954
|
});
|
|
953
955
|
var angularIslandSelector = "abs-angular-island", getAngularIslandSelector = (_islandId) => angularIslandSelector, isAngularComponent = (value) => typeof value === "function", getSelectorFromRenderedIsland = (rootElement) => {
|
|
954
956
|
const firstChild = rootElement.firstElementChild;
|
|
@@ -1010,8 +1012,10 @@ var angularIslandSelector = "abs-angular-island", getAngularIslandSelector = (_i
|
|
|
1010
1012
|
const propsToken = new InjectionToken2(`${wrapperKey}:props`);
|
|
1011
1013
|
|
|
1012
1014
|
class AngularIslandWrapperComponent {
|
|
1013
|
-
|
|
1014
|
-
|
|
1015
|
+
constructor() {
|
|
1016
|
+
this.component = component;
|
|
1017
|
+
this.props = inject(propsToken);
|
|
1018
|
+
}
|
|
1015
1019
|
}
|
|
1016
1020
|
return {
|
|
1017
1021
|
deps,
|
|
@@ -1460,13 +1464,13 @@ var init_nativeRewrite = __esm(() => {
|
|
|
1460
1464
|
// src/build/rewriteImportsPlugin.ts
|
|
1461
1465
|
var exports_rewriteImportsPlugin = {};
|
|
1462
1466
|
__export(exports_rewriteImportsPlugin, {
|
|
1463
|
-
|
|
1464
|
-
rewriteImportsInContent: () => rewriteImportsInContent,
|
|
1465
|
-
rewriteBuildOutputsWith: () => rewriteBuildOutputsWith,
|
|
1466
|
-
rewriteBuildOutputs: () => rewriteBuildOutputs,
|
|
1467
|
-
jsRewriteImports: () => jsRewriteImports,
|
|
1467
|
+
buildWithImportRewrite: () => buildWithImportRewrite,
|
|
1468
1468
|
fixMissingReExportNamespacesInContent: () => fixMissingReExportNamespacesInContent,
|
|
1469
|
-
|
|
1469
|
+
jsRewriteImports: () => jsRewriteImports,
|
|
1470
|
+
rewriteBuildOutputs: () => rewriteBuildOutputs,
|
|
1471
|
+
rewriteBuildOutputsWith: () => rewriteBuildOutputsWith,
|
|
1472
|
+
rewriteImportsInContent: () => rewriteImportsInContent,
|
|
1473
|
+
rewriteVendorDirectories: () => rewriteVendorDirectories
|
|
1470
1474
|
});
|
|
1471
1475
|
import { readdir } from "fs/promises";
|
|
1472
1476
|
import { join as join2 } from "path";
|
|
@@ -1880,22 +1884,22 @@ var init_lowerAwaitSlotSyntax = __esm(() => {
|
|
|
1880
1884
|
// src/build/stylePreprocessor.ts
|
|
1881
1885
|
var exports_stylePreprocessor = {};
|
|
1882
1886
|
__export(exports_stylePreprocessor, {
|
|
1883
|
-
|
|
1884
|
-
recordStyleOutput: () => recordStyleOutput,
|
|
1885
|
-
isStylePath: () => isStylePath,
|
|
1886
|
-
isStyleModulePath: () => isStyleModulePath,
|
|
1887
|
-
isPreprocessableStylePath: () => isPreprocessableStylePath,
|
|
1888
|
-
getStyleBaseName: () => getStyleBaseName,
|
|
1889
|
-
getCssOutputExtension: () => getCssOutputExtension,
|
|
1890
|
-
forgetStyleEntry: () => forgetStyleEntry,
|
|
1891
|
-
findStyleEntriesImporting: () => findStyleEntriesImporting,
|
|
1892
|
-
createSvelteStylePreprocessor: () => createSvelteStylePreprocessor,
|
|
1893
|
-
createStyleTransformConfig: () => createStyleTransformConfig,
|
|
1894
|
-
createStylePreprocessorPlugin: () => createStylePreprocessorPlugin,
|
|
1895
|
-
compileStyleSource: () => compileStyleSource,
|
|
1896
|
-
compileStyleFileIfNeededSync: () => compileStyleFileIfNeededSync,
|
|
1887
|
+
addStyleImporter: () => addStyleImporter,
|
|
1897
1888
|
compileStyleFileIfNeeded: () => compileStyleFileIfNeeded,
|
|
1898
|
-
|
|
1889
|
+
compileStyleFileIfNeededSync: () => compileStyleFileIfNeededSync,
|
|
1890
|
+
compileStyleSource: () => compileStyleSource,
|
|
1891
|
+
createStylePreprocessorPlugin: () => createStylePreprocessorPlugin,
|
|
1892
|
+
createStyleTransformConfig: () => createStyleTransformConfig,
|
|
1893
|
+
createSvelteStylePreprocessor: () => createSvelteStylePreprocessor,
|
|
1894
|
+
findStyleEntriesImporting: () => findStyleEntriesImporting,
|
|
1895
|
+
forgetStyleEntry: () => forgetStyleEntry,
|
|
1896
|
+
getCssOutputExtension: () => getCssOutputExtension,
|
|
1897
|
+
getStyleBaseName: () => getStyleBaseName,
|
|
1898
|
+
isPreprocessableStylePath: () => isPreprocessableStylePath,
|
|
1899
|
+
isStyleModulePath: () => isStyleModulePath,
|
|
1900
|
+
isStylePath: () => isStylePath,
|
|
1901
|
+
recordStyleOutput: () => recordStyleOutput,
|
|
1902
|
+
stylePreprocessorPlugin: () => stylePreprocessorPlugin
|
|
1899
1903
|
});
|
|
1900
1904
|
import { createHash } from "crypto";
|
|
1901
1905
|
import { existsSync as existsSync3, readFileSync as readFileSync3 } from "fs";
|
|
@@ -2996,10 +3000,10 @@ var init_renderIslandMarkup = __esm(() => {
|
|
|
2996
3000
|
// src/core/devRouteRegistrationCallsite.ts
|
|
2997
3001
|
var exports_devRouteRegistrationCallsite = {};
|
|
2998
3002
|
__export(exports_devRouteRegistrationCallsite, {
|
|
2999
|
-
|
|
3000
|
-
isPageHandler: () => isPageHandler,
|
|
3003
|
+
getCurrentRouteRegistrationCallsite: () => getCurrentRouteRegistrationCallsite,
|
|
3001
3004
|
getOriginalPageHandlerSource: () => getOriginalPageHandlerSource,
|
|
3002
|
-
|
|
3005
|
+
isPageHandler: () => isPageHandler,
|
|
3006
|
+
patchElysiaRouteRegistrationCallsites: () => patchElysiaRouteRegistrationCallsites
|
|
3003
3007
|
});
|
|
3004
3008
|
import { AsyncLocalStorage } from "async_hooks";
|
|
3005
3009
|
import { Elysia } from "elysia";
|
|
@@ -3854,6 +3858,7 @@ var colors, MONTHS, formatTimestamp = () => {
|
|
|
3854
3858
|
port,
|
|
3855
3859
|
host,
|
|
3856
3860
|
networkUrl,
|
|
3861
|
+
mobilePreviewUrl,
|
|
3857
3862
|
protocol = "http"
|
|
3858
3863
|
} = options;
|
|
3859
3864
|
const name = `${colors.cyan}${colors.bold}ABSOLUTEJS${colors.reset}`;
|
|
@@ -3867,6 +3872,9 @@ var colors, MONTHS, formatTimestamp = () => {
|
|
|
3867
3872
|
if (networkUrl) {
|
|
3868
3873
|
console.log(` ${colors.green}\u279C${colors.reset} ${colors.bold}Network:${colors.reset} ${networkUrl}`);
|
|
3869
3874
|
}
|
|
3875
|
+
if (mobilePreviewUrl) {
|
|
3876
|
+
console.log(` ${colors.green}\u279C${colors.reset} ${colors.bold}Mobile:${colors.reset} ${mobilePreviewUrl}`);
|
|
3877
|
+
}
|
|
3870
3878
|
console.log("");
|
|
3871
3879
|
};
|
|
3872
3880
|
var init_startupBanner = __esm(() => {
|
|
@@ -4517,8 +4525,8 @@ var init_lowerDeferSyntax = __esm(() => {
|
|
|
4517
4525
|
// src/utils/generatedDir.ts
|
|
4518
4526
|
var exports_generatedDir = {};
|
|
4519
4527
|
__export(exports_generatedDir, {
|
|
4520
|
-
|
|
4521
|
-
|
|
4528
|
+
getFrameworkGeneratedDir: () => getFrameworkGeneratedDir,
|
|
4529
|
+
getGeneratedRoot: () => getGeneratedRoot
|
|
4522
4530
|
});
|
|
4523
4531
|
import { join as join8 } from "path";
|
|
4524
4532
|
var GENERATED_DIR_NAME = "generated", ABSOLUTE_CACHE_DIR_NAME = ".absolutejs", getFrameworkGeneratedDir = (framework, projectRoot = process.cwd()) => join8(getGeneratedRoot(projectRoot), framework), getGeneratedRoot = (projectRoot = process.cwd()) => join8(projectRoot, ABSOLUTE_CACHE_DIR_NAME, GENERATED_DIR_NAME);
|
|
@@ -4527,17 +4535,25 @@ var init_generatedDir = () => {};
|
|
|
4527
4535
|
// src/build/compileAngular.ts
|
|
4528
4536
|
var exports_compileAngular = {};
|
|
4529
4537
|
__export(exports_compileAngular, {
|
|
4530
|
-
|
|
4531
|
-
compileAngularFiles: () => compileAngularFiles,
|
|
4532
|
-
compileAngularFileJIT: () => compileAngularFileJIT,
|
|
4538
|
+
compileAngular: () => compileAngular,
|
|
4533
4539
|
compileAngularFile: () => compileAngularFile,
|
|
4534
|
-
|
|
4540
|
+
compileAngularFileJIT: () => compileAngularFileJIT,
|
|
4541
|
+
compileAngularFiles: () => compileAngularFiles,
|
|
4542
|
+
invalidateAngularJitCache: () => invalidateAngularJitCache
|
|
4535
4543
|
});
|
|
4536
4544
|
import { existsSync as existsSync5, readFileSync as readFileSync5, promises as fs } from "fs";
|
|
4537
4545
|
import { join as join9, basename as basename4, sep, dirname as dirname5, resolve as resolve7, relative as relative5 } from "path";
|
|
4538
4546
|
var {Glob } = globalThis.Bun;
|
|
4539
4547
|
import ts from "typescript";
|
|
4540
|
-
var
|
|
4548
|
+
var atomicWriteSequence = 0, writeTextFileAtomically = async (path, content) => {
|
|
4549
|
+
const temporaryPath = `${path}.tmp.${process.pid}.${atomicWriteSequence++}`;
|
|
4550
|
+
try {
|
|
4551
|
+
await fs.writeFile(temporaryPath, content, "utf-8");
|
|
4552
|
+
await fs.rename(temporaryPath, path);
|
|
4553
|
+
} finally {
|
|
4554
|
+
await fs.rm(temporaryPath, { force: true });
|
|
4555
|
+
}
|
|
4556
|
+
}, traceAngularPhase = async (name, fn, metadata) => {
|
|
4541
4557
|
const tracePhase = globalThis.__absoluteBuildTracePhase;
|
|
4542
4558
|
return tracePhase ? tracePhase(`compile/angular/${name}`, fn, metadata) : await fn();
|
|
4543
4559
|
}, readTsconfigPathAliases = () => {
|
|
@@ -4803,10 +4819,10 @@ var traceAngularPhase = async (name, fn, metadata) => {
|
|
|
4803
4819
|
}
|
|
4804
4820
|
}, writeResourceCacheFile = async (cachePath, source) => {
|
|
4805
4821
|
await fs.mkdir(dirname5(cachePath), { recursive: true });
|
|
4806
|
-
await
|
|
4822
|
+
await writeTextFileAtomically(cachePath, JSON.stringify({
|
|
4807
4823
|
source,
|
|
4808
4824
|
version: 1
|
|
4809
|
-
})
|
|
4825
|
+
}));
|
|
4810
4826
|
}, resolveResourceTransformCachePath = async (filePath, source, stylePreprocessors) => {
|
|
4811
4827
|
const resourcePaths = collectAngularResourcePaths(source, dirname5(filePath));
|
|
4812
4828
|
const resourceContents = await Promise.all(resourcePaths.map(async (resourcePath) => {
|
|
@@ -4992,7 +5008,7 @@ var traceAngularPhase = async (name, fn, metadata) => {
|
|
|
4992
5008
|
});
|
|
4993
5009
|
await traceAngularPhase("aot/write-output", () => Promise.all(entries.map(async ({ target, content }) => {
|
|
4994
5010
|
await fs.mkdir(dirname5(target), { recursive: true });
|
|
4995
|
-
await
|
|
5011
|
+
await writeTextFileAtomically(target, content);
|
|
4996
5012
|
})), { outputs: entries.length });
|
|
4997
5013
|
return await traceAngularPhase("aot/collect-output-paths", () => entries.map(({ target }) => target), { outputs: entries.length });
|
|
4998
5014
|
}, compileAngularFile = async (inputPath, outDir, stylePreprocessors) => compileAngularFiles([inputPath], outDir, stylePreprocessors), jitContentCache, invalidateAngularJitCache = (filePath) => {
|
|
@@ -5457,7 +5473,7 @@ ${fields}
|
|
|
5457
5473
|
const processedContent = transpileAndRewrite(sourceCode, relativeDir, actualPath, importRewrites);
|
|
5458
5474
|
const preservedInjection = await readPreservedInjection(targetPath);
|
|
5459
5475
|
await fs.mkdir(targetDir, { recursive: true });
|
|
5460
|
-
await
|
|
5476
|
+
await writeTextFileAtomically(targetPath, processedContent + preservedInjection);
|
|
5461
5477
|
jitContentCache.set(cacheKey, contentHash);
|
|
5462
5478
|
}
|
|
5463
5479
|
allOutputs.push(targetPath);
|
|
@@ -5473,7 +5489,7 @@ ${fields}
|
|
|
5473
5489
|
export const __ABSOLUTE_PAGE_USES_LEGACY_ANIMATIONS__ = true;
|
|
5474
5490
|
` : withoutLegacyFlag;
|
|
5475
5491
|
if (nextEntryOutput !== entryOutput) {
|
|
5476
|
-
await
|
|
5492
|
+
await writeTextFileAtomically(entryOutputPath, nextEntryOutput);
|
|
5477
5493
|
}
|
|
5478
5494
|
}
|
|
5479
5495
|
return allOutputs;
|
|
@@ -5643,7 +5659,7 @@ export const providers = [${fragments.join(", ")}];
|
|
|
5643
5659
|
`;
|
|
5644
5660
|
}
|
|
5645
5661
|
}
|
|
5646
|
-
await traceAngularPhase("wrapper/write-server-output", () =>
|
|
5662
|
+
await traceAngularPhase("wrapper/write-server-output", () => writeTextFileAtomically(rawServerFile, rewritten), { entry: resolvedEntry });
|
|
5647
5663
|
const relativePath = relative5(indexesDir, rawServerFile).replace(/\\/g, "/");
|
|
5648
5664
|
const normalizedImportPath = relativePath.startsWith(".") ? relativePath : `./${relativePath}`;
|
|
5649
5665
|
const hmrPreamble = hmr ? `window.__HMR_FRAMEWORK__ = "angular";
|
|
@@ -5842,7 +5858,7 @@ window.__ABSOLUTE_PAGE_DISPOSE__ = async function() {
|
|
|
5842
5858
|
`.trim();
|
|
5843
5859
|
const indexHash = Bun.hash(hydration).toString(BASE_36_RADIX);
|
|
5844
5860
|
const indexUnchanged = cachedWrapper?.indexHash === indexHash;
|
|
5845
|
-
await traceAngularPhase("wrapper/write-client-index", () =>
|
|
5861
|
+
await traceAngularPhase("wrapper/write-client-index", () => writeTextFileAtomically(clientFile, hydration), { entry: resolvedEntry });
|
|
5846
5862
|
wrapperOutputCache.set(resolvedEntry, {
|
|
5847
5863
|
indexHash,
|
|
5848
5864
|
serverHash: serverContentHash
|
|
@@ -6484,6 +6500,7 @@ var getCurrentAbsoluteMobileProducerContext = () => {
|
|
|
6484
6500
|
// src/mobile/pageProtocol.ts
|
|
6485
6501
|
var ABSOLUTE_MOBILE_PAGE_MEDIA_TYPE = "application/vnd.absolute.page+json";
|
|
6486
6502
|
var ABSOLUTE_MOBILE_PAGE_PROTOCOL_VERSION = 1;
|
|
6503
|
+
var ABSOLUTE_NATIVE_ROUTE_DATA_MEDIA_TYPE = "application/vnd.absolute.native-route+json";
|
|
6487
6504
|
var BAD_REQUEST_STATUS = 400;
|
|
6488
6505
|
var OK_STATUS = 200;
|
|
6489
6506
|
var SERVER_ERROR_STATUS = 500;
|
|
@@ -6502,6 +6519,11 @@ var acceptsAbsoluteMobilePage = (request) => {
|
|
|
6502
6519
|
return false;
|
|
6503
6520
|
return (request.headers.get("accept") ?? "").split(",").some((value) => parseMediaType(value) === ABSOLUTE_MOBILE_PAGE_MEDIA_TYPE);
|
|
6504
6521
|
};
|
|
6522
|
+
var acceptsAbsoluteNativeRouteData = (request) => {
|
|
6523
|
+
if (!request)
|
|
6524
|
+
return false;
|
|
6525
|
+
return (request.headers.get("accept") ?? "").split(",").some((value) => parseMediaType(value) === ABSOLUTE_NATIVE_ROUTE_DATA_MEDIA_TYPE);
|
|
6526
|
+
};
|
|
6505
6527
|
var readRequiredHeader = (request, name) => {
|
|
6506
6528
|
const value = request.headers.get(name)?.trim();
|
|
6507
6529
|
return value ? value : undefined;
|
|
@@ -6632,6 +6654,32 @@ var finalizeArchivedMobilePage = (context, input) => {
|
|
|
6632
6654
|
return createAbsoluteMobilePageErrorResponse(page.pageId);
|
|
6633
6655
|
}
|
|
6634
6656
|
};
|
|
6657
|
+
var finalizeAbsoluteNativeRouteDevelopmentPage = (input) => {
|
|
6658
|
+
if (false) {}
|
|
6659
|
+
if (input.request?.method !== "GET") {
|
|
6660
|
+
return createAbsoluteMobileInvalidRequestResponse("Native-route data requests must use GET.");
|
|
6661
|
+
}
|
|
6662
|
+
if (input.request.headers.get(MOBILE_PAGE_REQUEST_HEADERS.protocol) !== String(ABSOLUTE_MOBILE_PAGE_PROTOCOL_VERSION)) {
|
|
6663
|
+
return createAbsoluteMobileInvalidRequestResponse(`Native-route data requires protocol ${ABSOLUTE_MOBILE_PAGE_PROTOCOL_VERSION}.`);
|
|
6664
|
+
}
|
|
6665
|
+
const [representation] = input.compatibility.representations;
|
|
6666
|
+
if (!representation) {
|
|
6667
|
+
return createAbsoluteMobilePageErrorResponse(input.compatibility.pageId);
|
|
6668
|
+
}
|
|
6669
|
+
try {
|
|
6670
|
+
return envelopeResponse({
|
|
6671
|
+
contract: representation.contract,
|
|
6672
|
+
framework: input.compatibility.framework,
|
|
6673
|
+
kind: "page",
|
|
6674
|
+
pageId: input.compatibility.pageId,
|
|
6675
|
+
props: normalizeJsonValue(representation.mapProps(input.props)),
|
|
6676
|
+
status: input.status ?? OK_STATUS
|
|
6677
|
+
}, input.status ?? OK_STATUS);
|
|
6678
|
+
} catch (error) {
|
|
6679
|
+
console.error(`[Mobile] Failed to produce development native route ${input.compatibility.pageId}:`, error);
|
|
6680
|
+
return createAbsoluteMobilePageErrorResponse(input.compatibility.pageId);
|
|
6681
|
+
}
|
|
6682
|
+
};
|
|
6635
6683
|
var createAbsoluteMobileInvalidRequestResponse = (message) => envelopeResponse({ kind: "invalid-request", message }, BAD_REQUEST_STATUS);
|
|
6636
6684
|
var createAbsoluteMobilePageErrorResponse = (pageId) => envelopeResponse({
|
|
6637
6685
|
code: "representation-failed",
|
|
@@ -6641,6 +6689,9 @@ var createAbsoluteMobilePageErrorResponse = (pageId) => envelopeResponse({
|
|
|
6641
6689
|
}, SERVER_ERROR_STATUS);
|
|
6642
6690
|
var createAbsoluteMobileUpgradeResponse = (result) => envelopeResponse(result, UPGRADE_REQUIRED_STATUS);
|
|
6643
6691
|
var finalizeAbsoluteMobilePage = (input) => {
|
|
6692
|
+
if (acceptsAbsoluteNativeRouteData(input.request)) {
|
|
6693
|
+
return finalizeAbsoluteNativeRouteDevelopmentPage(input);
|
|
6694
|
+
}
|
|
6644
6695
|
const parsed = parseAbsoluteMobilePageRequest(input.request);
|
|
6645
6696
|
if (parsed.kind === "not-mobile")
|
|
6646
6697
|
return;
|
|
@@ -7120,16 +7171,16 @@ var withPendingTask = async (work) => {
|
|
|
7120
7171
|
}
|
|
7121
7172
|
};
|
|
7122
7173
|
export {
|
|
7123
|
-
|
|
7124
|
-
provideDeterministicEnv,
|
|
7125
|
-
handleAngularPageRequest,
|
|
7126
|
-
createDeterministicRandom,
|
|
7127
|
-
buildAbsoluteHttpTransferCacheOptions,
|
|
7128
|
-
DETERMINISTIC_SEED,
|
|
7129
|
-
DETERMINISTIC_RANDOM,
|
|
7174
|
+
ABSOLUTE_HTTP_TRANSFER_CACHE_SKIP_HEADER,
|
|
7130
7175
|
DETERMINISTIC_NOW,
|
|
7131
|
-
|
|
7176
|
+
DETERMINISTIC_RANDOM,
|
|
7177
|
+
DETERMINISTIC_SEED,
|
|
7178
|
+
buildAbsoluteHttpTransferCacheOptions,
|
|
7179
|
+
createDeterministicRandom,
|
|
7180
|
+
handleAngularPageRequest,
|
|
7181
|
+
provideDeterministicEnv,
|
|
7182
|
+
withPendingTask
|
|
7132
7183
|
};
|
|
7133
7184
|
|
|
7134
|
-
//# debugId=
|
|
7185
|
+
//# debugId=A664694154EAE2F664756E2164756E21
|
|
7135
7186
|
//# sourceMappingURL=server.js.map
|