@absolutejs/absolute 0.20.0-beta.120 → 0.20.0-beta.122
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/CHANGELOG.md +21 -0
- package/changelog.json +37 -0
- package/dist/angular/components/core/streamingSlotRegistrar.js +1 -1
- package/dist/angular/components/core/streamingSlotRegistry.js +2 -2
- package/dist/angular/index.js +14 -2
- package/dist/angular/index.js.map +5 -4
- package/dist/angular/server.js +14 -2
- package/dist/angular/server.js.map +5 -4
- package/dist/build.js +15 -3
- package/dist/build.js.map +6 -5
- package/dist/cli/{add-kt4qx8sh.js → add-9sa7e3vd.js} +5 -5
- package/dist/cli/{androidEmulatorController-v6chbhem.js → androidEmulatorController-sj141e1c.js} +3 -3
- package/dist/cli/{androidNativeWatcher-mgqws6ag.js → androidNativeWatcher-dnp95nk2.js} +3 -3
- package/dist/cli/{api-xtq3zqfg.js → api-2hd8cahp.js} +1 -1
- package/dist/cli/{compile-5m830csy.js → compile-hywymh6y.js} +1 -1
- package/dist/cli/config/server.js +59 -9
- package/dist/cli/db-8wweexdp.js +1100 -0
- package/dist/cli/{dev-ww30tdrv.js → dev-pdefc9ac.js} +9 -9
- package/dist/cli/{emulatorDoctor-y2nqmaha.js → emulatorDoctor-gzarrsex.js} +2 -2
- package/dist/cli/{emulatorInstaller-3shdna4g.js → emulatorInstaller-pjw4ex6q.js} +3 -3
- package/dist/cli/{expoDevController-zz516pdd.js → expoDevController-weywa74d.js} +3 -3
- package/dist/cli/{generate-zy3d9bce.js → generate-069p0dk3.js} +4 -4
- package/dist/cli/{htmx-63kt9qj1.js → htmx-5wh1jh75.js} +2 -2
- package/dist/cli/{index-t84wxk1p.js → index-00wfffav.js} +50 -8
- package/dist/cli/{index-wtyg9cy0.js → index-1ys3dnrs.js} +1 -1
- package/dist/cli/{index-knt92dm8.js → index-255xs63d.js} +1 -1
- package/dist/cli/{index-wspj2mq3.js → index-3x5wpx5d.js} +1 -1
- package/dist/cli/{index-28nxv57v.js → index-5cgsrv62.js} +12 -2
- package/dist/cli/{index-mxmg15c5.js → index-ddakkws4.js} +2 -2
- package/dist/cli/{index-ce870r79.js → index-erngp7a9.js} +1 -1
- package/dist/cli/{index-pa3hmzj7.js → index-j2nw3edf.js} +1 -1
- package/dist/cli/{index-1wgc9e0v.js → index-keg69zm1.js} +1 -1
- package/dist/cli/{index-5268nwjx.js → index-q3sq287p.js} +1 -1
- package/dist/cli/{index-jf1f6npt.js → index-rqbk0b30.js} +1 -1
- package/dist/cli/{index-q1d4ns4n.js → index-v26ze17p.js} +1 -1
- package/dist/cli/{index-hneb973j.js → index-vkkqe08e.js} +2 -2
- package/dist/cli/index.js +23 -18
- package/dist/cli/{info-crpftzxh.js → info-d74dr585.js} +1 -1
- package/dist/cli/{iosNativeWatcher-8w1gawg4.js → iosNativeWatcher-kggp7j9a.js} +4 -4
- package/dist/cli/{iosSimulatorController-5vhqvhg6.js → iosSimulatorController-xcxxfkzx.js} +4 -4
- package/dist/cli/{mobile-21vsmrjd.js → mobile-00bqw12c.js} +9 -9
- package/dist/cli/{ps-ha7bhpc6.js → ps-8y28kzmb.js} +1 -1
- package/dist/cli/{psTui-rxszyyz8.js → psTui-8e96mwgz.js} +1 -1
- package/dist/cli/{remoteMacProtocol-dybpgazw.js → remoteMacProtocol-r38jhg44.js} +4 -4
- package/dist/cli/{remove-pwfv4wsd.js → remove-3fd1z2hx.js} +4 -4
- package/dist/cli/{start-3bhf56tj.js → start-q08avhxg.js} +2 -2
- package/dist/cli/{typecheck-7n5599tp.js → typecheck-yj9s13eb.js} +1 -1
- package/dist/cli/{workspace-h7czpaqh.js → workspace-e3jt4as8.js} +1 -1
- package/dist/client/chunks/index-dk743xs6.js +146 -0
- package/dist/client/chunks/index-dk743xs6.js.map +10 -0
- package/dist/client/chunks/index-jrcwp722.js +12 -0
- package/dist/client/chunks/index-jrcwp722.js.map +10 -0
- package/dist/client/chunks/{islands-xj2n8nwf.js → islands-50dg63j9.js} +6 -3
- package/dist/client/chunks/{islands-xj2n8nwf.js.map → islands-50dg63j9.js.map} +3 -3
- package/dist/client/chunks/{react-pdg4325x.js → react-yq4ss9y4.js} +4 -3
- package/dist/client/chunks/{react-pdg4325x.js.map → react-yq4ss9y4.js.map} +2 -2
- package/dist/client/index.js +5 -4
- package/dist/client/index.js.map +2 -2
- package/dist/index.js +15 -3
- package/dist/index.js.map +6 -5
- package/dist/islands/index.js +14 -2
- package/dist/islands/index.js.map +5 -4
- package/dist/mobile/index.js +13 -3
- package/dist/mobile/index.js.map +4 -4
- package/dist/mobile/remoteMacAgentEntry.js +162 -162
- package/dist/react/index.js +14 -2
- package/dist/react/index.js.map +5 -4
- package/dist/react/server.js +14 -2
- package/dist/react/server.js.map +5 -4
- package/dist/src/cli/scripts/db.d.ts +2 -19
- package/dist/src/cli/scripts/dbEngines/detect.d.ts +8 -0
- package/dist/src/cli/scripts/dbEngines/mssql.d.ts +4 -0
- package/dist/src/cli/scripts/dbEngines/mysql.d.ts +2 -0
- package/dist/src/cli/scripts/dbEngines/open.d.ts +2 -0
- package/dist/src/cli/scripts/dbEngines/postgres.d.ts +2 -0
- package/dist/src/cli/scripts/dbEngines/sqlText.d.ts +13 -0
- package/dist/src/cli/scripts/dbEngines/sqlite.d.ts +4 -0
- package/dist/src/cli/scripts/dbEngines/values.d.ts +12 -0
- package/dist/src/cli/utils.d.ts +7 -0
- package/dist/src/client/browserTranslation.d.ts +3 -0
- package/dist/src/client/browserTranslationAttributes.d.ts +2 -0
- package/dist/src/utils/userAgentFunctions.d.ts +1 -1
- package/dist/src/vue/components/Image.d.ts +1 -1
- package/dist/svelte/index.js +14 -2
- package/dist/svelte/index.js.map +5 -4
- package/dist/svelte/server.js +14 -2
- package/dist/svelte/server.js.map +5 -4
- package/dist/types/db.d.ts +109 -0
- package/dist/vue/browser.js +75 -8
- package/dist/vue/browser.js.map +5 -4
- package/dist/vue/index.js +77 -9
- package/dist/vue/index.js.map +6 -5
- package/dist/vue/server.js +14 -2
- package/dist/vue/server.js.map +5 -4
- package/package.json +13 -1
- package/dist/cli/db-tejnwt9j.js +0 -238
- package/dist/client/chunks/index-5py90ctf.js +0 -87
- package/dist/client/chunks/index-5py90ctf.js.map +0 -10
|
@@ -28,11 +28,11 @@ import {
|
|
|
28
28
|
syncAbsoluteRemoteMacReleaseInputs,
|
|
29
29
|
validateAbsoluteRemoteMacProfileName,
|
|
30
30
|
validateAbsoluteSshDestination
|
|
31
|
-
} from "./index-
|
|
32
|
-
import"./index-
|
|
31
|
+
} from "./index-rqbk0b30.js";
|
|
32
|
+
import"./index-v26ze17p.js";
|
|
33
33
|
import"./index-bw4ktfnz.js";
|
|
34
|
-
import"./index-
|
|
35
|
-
import"./index-
|
|
34
|
+
import"./index-255xs63d.js";
|
|
35
|
+
import"./index-00wfffav.js";
|
|
36
36
|
import"./index-wtfnv3n2.js";
|
|
37
37
|
import"./index-prwyfnn3.js";
|
|
38
38
|
import"./index-czwrxgdj.js";
|
|
@@ -1,24 +1,24 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
applyAbsoluteConfigEdit
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-3x5wpx5d.js";
|
|
5
5
|
import {
|
|
6
6
|
frameworkDependencyNames
|
|
7
7
|
} from "./index-zh6hhrwy.js";
|
|
8
8
|
import {
|
|
9
9
|
findRoutingFile
|
|
10
|
-
} from "./index-
|
|
10
|
+
} from "./index-j2nw3edf.js";
|
|
11
11
|
import {
|
|
12
12
|
frameworks,
|
|
13
13
|
isFrameworkKey,
|
|
14
14
|
resolveProject
|
|
15
|
-
} from "./index-
|
|
15
|
+
} from "./index-keg69zm1.js";
|
|
16
16
|
import"./index-v1k46q3x.js";
|
|
17
17
|
import {
|
|
18
18
|
colors
|
|
19
19
|
} from "./index-8nym68py.js";
|
|
20
20
|
import"./index-06cmrcdq.js";
|
|
21
|
-
import"./index-
|
|
21
|
+
import"./index-00wfffav.js";
|
|
22
22
|
import"./index-wtfnv3n2.js";
|
|
23
23
|
import"./index-prwyfnn3.js";
|
|
24
24
|
import"./index-czwrxgdj.js";
|
|
@@ -1,7 +1,7 @@
|
|
|
1
1
|
// @bun
|
|
2
2
|
import {
|
|
3
3
|
start
|
|
4
|
-
} from "./index-
|
|
4
|
+
} from "./index-q3sq287p.js";
|
|
5
5
|
import"./index-k8r00xh9.js";
|
|
6
6
|
import"./index-bzs19w3r.js";
|
|
7
7
|
import"./index-s2tazax7.js";
|
|
@@ -13,7 +13,7 @@ import"./index-w5vswatm.js";
|
|
|
13
13
|
import"./index-exdd5k1g.js";
|
|
14
14
|
import"./index-nxcwg9ma.js";
|
|
15
15
|
import"./index-ar4gz15x.js";
|
|
16
|
-
import"./index-
|
|
16
|
+
import"./index-00wfffav.js";
|
|
17
17
|
import"./index-wtfnv3n2.js";
|
|
18
18
|
import"./index-prwyfnn3.js";
|
|
19
19
|
import"./index-czwrxgdj.js";
|
|
@@ -0,0 +1,146 @@
|
|
|
1
|
+
import {
|
|
2
|
+
TRANSLATABLE_ATTRIBUTES
|
|
3
|
+
} from "./index-jrcwp722.js";
|
|
4
|
+
|
|
5
|
+
// src/client/browserTranslation.ts
|
|
6
|
+
var translatedFontText = (node, baselines) => {
|
|
7
|
+
if (!(node instanceof Element) || node.tagName !== "FONT")
|
|
8
|
+
return;
|
|
9
|
+
const elements = [node, ...node.querySelectorAll("*")];
|
|
10
|
+
if (elements.some((element) => element.tagName !== "FONT" || baselines.has(element)))
|
|
11
|
+
return;
|
|
12
|
+
return node.textContent ?? "";
|
|
13
|
+
};
|
|
14
|
+
var translationRestorer = (restore, hasTranslation) => Object.assign(restore, { hasTranslation });
|
|
15
|
+
var emptyTranslationRestorer = () => translationRestorer(() => {
|
|
16
|
+
return;
|
|
17
|
+
}, false);
|
|
18
|
+
var textNodeAt = (parent, index) => {
|
|
19
|
+
const node = parent.childNodes[index];
|
|
20
|
+
return node instanceof Text ? node : undefined;
|
|
21
|
+
};
|
|
22
|
+
var prepareTextTranslation = (element, index, baseline, path, baselines) => {
|
|
23
|
+
const original = element.childNodes[index];
|
|
24
|
+
const wrappedText = translatedFontText(original, baselines);
|
|
25
|
+
if (wrappedText !== undefined) {
|
|
26
|
+
original?.replaceWith(document.createTextNode(baseline));
|
|
27
|
+
return { baseline, index, path, translated: wrappedText };
|
|
28
|
+
}
|
|
29
|
+
const node = textNodeAt(element, index);
|
|
30
|
+
if (node === undefined || node.data === baseline)
|
|
31
|
+
return;
|
|
32
|
+
const snapshot = {
|
|
33
|
+
baseline,
|
|
34
|
+
index,
|
|
35
|
+
path,
|
|
36
|
+
translated: node.data
|
|
37
|
+
};
|
|
38
|
+
node.data = baseline;
|
|
39
|
+
return snapshot;
|
|
40
|
+
};
|
|
41
|
+
var visitElements = (root, visit) => {
|
|
42
|
+
visit(root);
|
|
43
|
+
for (const element of root.querySelectorAll("*"))
|
|
44
|
+
visit(element);
|
|
45
|
+
};
|
|
46
|
+
var elementPath = (root, element) => {
|
|
47
|
+
const path = [];
|
|
48
|
+
let current = element;
|
|
49
|
+
while (current !== root) {
|
|
50
|
+
const parent = current.parentElement;
|
|
51
|
+
if (parent === null)
|
|
52
|
+
return null;
|
|
53
|
+
path.unshift([...parent.children].indexOf(current));
|
|
54
|
+
current = parent;
|
|
55
|
+
}
|
|
56
|
+
return path;
|
|
57
|
+
};
|
|
58
|
+
var elementAtPath = (root, path) => {
|
|
59
|
+
let current = root;
|
|
60
|
+
for (const index of path) {
|
|
61
|
+
const child = current.children[index];
|
|
62
|
+
if (!(child instanceof Element))
|
|
63
|
+
return null;
|
|
64
|
+
current = child;
|
|
65
|
+
}
|
|
66
|
+
return current;
|
|
67
|
+
};
|
|
68
|
+
var captureSsrTextBaselines = (root) => {
|
|
69
|
+
if (root === null || typeof window === "undefined")
|
|
70
|
+
return;
|
|
71
|
+
const baselines = window.__ABSOLUTE_SSR_TEXT_BASELINES__ ?? new WeakMap;
|
|
72
|
+
const attributes = window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__ ?? new WeakMap;
|
|
73
|
+
visitElements(root, (element) => {
|
|
74
|
+
const text = new Map;
|
|
75
|
+
for (const [index, node] of [...element.childNodes].entries()) {
|
|
76
|
+
if (node.nodeType === Node.TEXT_NODE)
|
|
77
|
+
text.set(index, node.nodeValue ?? "");
|
|
78
|
+
}
|
|
79
|
+
if (text.size > 0)
|
|
80
|
+
baselines.set(element, text);
|
|
81
|
+
const values = new Map;
|
|
82
|
+
for (const name of TRANSLATABLE_ATTRIBUTES) {
|
|
83
|
+
const value = element.getAttribute(name);
|
|
84
|
+
if (value !== null)
|
|
85
|
+
values.set(name, value);
|
|
86
|
+
}
|
|
87
|
+
if (values.size > 0)
|
|
88
|
+
attributes.set(element, values);
|
|
89
|
+
});
|
|
90
|
+
window.__ABSOLUTE_SSR_TEXT_BASELINES__ = baselines;
|
|
91
|
+
window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__ = attributes;
|
|
92
|
+
};
|
|
93
|
+
var prepareBrowserTranslationHydration = (root) => {
|
|
94
|
+
if (root === null || typeof window === "undefined")
|
|
95
|
+
return emptyTranslationRestorer();
|
|
96
|
+
const baselines = window.__ABSOLUTE_SSR_TEXT_BASELINES__;
|
|
97
|
+
if (baselines === undefined)
|
|
98
|
+
return emptyTranslationRestorer();
|
|
99
|
+
const translated = [];
|
|
100
|
+
const translatedAttributes = [];
|
|
101
|
+
const attributes = window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__;
|
|
102
|
+
visitElements(root, (element) => {
|
|
103
|
+
const text = baselines.get(element);
|
|
104
|
+
const path = elementPath(root, element);
|
|
105
|
+
if (path === null)
|
|
106
|
+
return;
|
|
107
|
+
for (const [index, baseline] of text ?? []) {
|
|
108
|
+
const snapshot = prepareTextTranslation(element, index, baseline, path, baselines);
|
|
109
|
+
if (snapshot === undefined)
|
|
110
|
+
continue;
|
|
111
|
+
translated.push(snapshot);
|
|
112
|
+
}
|
|
113
|
+
for (const [name, baseline] of attributes?.get(element) ?? []) {
|
|
114
|
+
const value = element.getAttribute(name);
|
|
115
|
+
if (value === null || value === baseline)
|
|
116
|
+
continue;
|
|
117
|
+
translatedAttributes.push({
|
|
118
|
+
baseline,
|
|
119
|
+
name,
|
|
120
|
+
path,
|
|
121
|
+
translated: value
|
|
122
|
+
});
|
|
123
|
+
element.setAttribute(name, baseline);
|
|
124
|
+
}
|
|
125
|
+
});
|
|
126
|
+
return translationRestorer(() => {
|
|
127
|
+
for (const snapshot of translated) {
|
|
128
|
+
const parent = elementAtPath(root, snapshot.path);
|
|
129
|
+
if (parent === null)
|
|
130
|
+
continue;
|
|
131
|
+
const node = textNodeAt(parent, snapshot.index);
|
|
132
|
+
if (node !== undefined && node.data === snapshot.baseline)
|
|
133
|
+
node.data = snapshot.translated;
|
|
134
|
+
}
|
|
135
|
+
for (const snapshot of translatedAttributes) {
|
|
136
|
+
const element = elementAtPath(root, snapshot.path);
|
|
137
|
+
if (element?.getAttribute(snapshot.name) === snapshot.baseline)
|
|
138
|
+
element.setAttribute(snapshot.name, snapshot.translated);
|
|
139
|
+
}
|
|
140
|
+
}, translated.length > 0 || translatedAttributes.length > 0);
|
|
141
|
+
};
|
|
142
|
+
|
|
143
|
+
export { captureSsrTextBaselines, prepareBrowserTranslationHydration };
|
|
144
|
+
|
|
145
|
+
//# debugId=2B49FE79D0C510E564756E2164756E21
|
|
146
|
+
//# sourceMappingURL=index-dk743xs6.js.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../src/client/browserTranslation.ts"],
|
|
4
|
+
"sourcesContent": [
|
|
5
|
+
"import { TRANSLATABLE_ATTRIBUTES } from './browserTranslationAttributes';\n\ntype TextBaseline = ReadonlyMap<number, string>;\ntype SsrTextBaselines = WeakMap<Element, TextBaseline>;\ntype AttributeBaseline = ReadonlyMap<string, string>;\ntype SsrAttributeBaselines = WeakMap<Element, AttributeBaseline>;\n\ndeclare global {\n\t// Window augmentation requires interface declaration merging.\n\t// eslint-disable-next-line @typescript-eslint/consistent-type-definitions\n\tinterface Window {\n\t\t__ABSOLUTE_SSR_TEXT_BASELINES__?: SsrTextBaselines;\n\t\t__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__?: SsrAttributeBaselines;\n\t}\n}\n\ntype TranslatedText = {\n\tbaseline: string;\n\tindex: number;\n\tpath: number[];\n\ttranslated: string;\n};\n\ntype TranslatedAttribute = {\n\tbaseline: string;\n\tname: string;\n\tpath: number[];\n\ttranslated: string;\n};\n\n// Translate inserts font wrappers around text. Remove only newly inserted,\n// text-only font trees; never flatten authored elements or interactive markup.\nconst translatedFontText = (\n\tnode: Node | undefined,\n\tbaselines: SsrTextBaselines\n) => {\n\tif (!(node instanceof Element) || node.tagName !== 'FONT') return undefined;\n\tconst elements = [node, ...node.querySelectorAll('*')];\n\tif (\n\t\telements.some(\n\t\t\t(element) => element.tagName !== 'FONT' || baselines.has(element)\n\t\t)\n\t)\n\t\treturn undefined;\n\n\treturn node.textContent ?? '';\n};\n\nconst translationRestorer = (restore: () => void, hasTranslation: boolean) =>\n\tObject.assign(restore, { hasTranslation });\n\nconst emptyTranslationRestorer = () =>\n\ttranslationRestorer(() => undefined, false);\n\nconst textNodeAt = (parent: Element, index: number) => {\n\tconst node = parent.childNodes[index];\n\n\treturn node instanceof Text ? node : undefined;\n};\n\nconst prepareTextTranslation = (\n\telement: Element,\n\tindex: number,\n\tbaseline: string,\n\tpath: number[],\n\tbaselines: SsrTextBaselines\n) => {\n\tconst original = element.childNodes[index];\n\tconst wrappedText = translatedFontText(original, baselines);\n\tif (wrappedText !== undefined) {\n\t\toriginal?.replaceWith(document.createTextNode(baseline));\n\n\t\treturn { baseline, index, path, translated: wrappedText };\n\t}\n\tconst node = textNodeAt(element, index);\n\tif (node === undefined || node.data === baseline) return undefined;\n\tconst snapshot: TranslatedText = {\n\t\tbaseline,\n\t\tindex,\n\t\tpath,\n\t\ttranslated: node.data\n\t};\n\tnode.data = baseline;\n\n\treturn snapshot;\n};\n\nconst visitElements = (root: Element, visit: (element: Element) => void) => {\n\tvisit(root);\n\tfor (const element of root.querySelectorAll('*')) visit(element);\n};\n\nconst elementPath = (root: Element, element: Element) => {\n\tconst path: number[] = [];\n\tlet current = element;\n\twhile (current !== root) {\n\t\tconst parent = current.parentElement;\n\t\tif (parent === null) return null;\n\t\tpath.unshift([...parent.children].indexOf(current));\n\t\tcurrent = parent;\n\t}\n\n\treturn path;\n};\n\nconst elementAtPath = (root: Element, path: number[]) => {\n\tlet current = root;\n\tfor (const index of path) {\n\t\tconst child = current.children[index];\n\t\tif (!(child instanceof Element)) return null;\n\t\tcurrent = child;\n\t}\n\n\treturn current;\n};\n\n/** Capture server-authored text before client modules load. Absolute page\n * handlers install the same snapshot inline; this export supports custom\n * documents and non-standard bootstraps. */\nexport const captureSsrTextBaselines = (root: Element | null) => {\n\tif (root === null || typeof window === 'undefined') return;\n\tconst baselines: SsrTextBaselines =\n\t\twindow.__ABSOLUTE_SSR_TEXT_BASELINES__ ?? new WeakMap();\n\tconst attributes: SsrAttributeBaselines =\n\t\twindow.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__ ?? new WeakMap();\n\tvisitElements(root, (element) => {\n\t\tconst text = new Map<number, string>();\n\t\tfor (const [index, node] of [...element.childNodes].entries()) {\n\t\t\tif (node.nodeType === Node.TEXT_NODE)\n\t\t\t\ttext.set(index, node.nodeValue ?? '');\n\t\t}\n\t\tif (text.size > 0) baselines.set(element, text);\n\t\tconst values = new Map<string, string>();\n\t\tfor (const name of TRANSLATABLE_ATTRIBUTES) {\n\t\t\tconst value = element.getAttribute(name);\n\t\t\tif (value !== null) values.set(name, value);\n\t\t}\n\t\tif (values.size > 0) attributes.set(element, values);\n\t});\n\twindow.__ABSOLUTE_SSR_TEXT_BASELINES__ = baselines;\n\twindow.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__ = attributes;\n};\n\n/** Temporarily restore server text while a framework attaches to SSR DOM,\n * then reapply translated text. Paths preserve translations even when a\n * framework replaces nodes while mounting. Genuine server/client mismatches\n * are left unchanged. */\nexport const prepareBrowserTranslationHydration = (root: Element | null) => {\n\tif (root === null || typeof window === 'undefined')\n\t\treturn emptyTranslationRestorer();\n\tconst baselines = window.__ABSOLUTE_SSR_TEXT_BASELINES__;\n\tif (baselines === undefined) return emptyTranslationRestorer();\n\tconst translated: TranslatedText[] = [];\n\tconst translatedAttributes: TranslatedAttribute[] = [];\n\tconst attributes = window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__;\n\tvisitElements(root, (element) => {\n\t\tconst text = baselines.get(element);\n\t\tconst path = elementPath(root, element);\n\t\tif (path === null) return;\n\t\tfor (const [index, baseline] of text ?? []) {\n\t\t\tconst snapshot = prepareTextTranslation(\n\t\t\t\telement,\n\t\t\t\tindex,\n\t\t\t\tbaseline,\n\t\t\t\tpath,\n\t\t\t\tbaselines\n\t\t\t);\n\t\t\tif (snapshot === undefined) continue;\n\t\t\ttranslated.push(snapshot);\n\t\t}\n\t\tfor (const [name, baseline] of attributes?.get(element) ?? []) {\n\t\t\tconst value = element.getAttribute(name);\n\t\t\tif (value === null || value === baseline) continue;\n\t\t\ttranslatedAttributes.push({\n\t\t\t\tbaseline,\n\t\t\t\tname,\n\t\t\t\tpath,\n\t\t\t\ttranslated: value\n\t\t\t});\n\t\t\telement.setAttribute(name, baseline);\n\t\t}\n\t});\n\n\treturn translationRestorer(\n\t\t() => {\n\t\t\tfor (const snapshot of translated) {\n\t\t\t\tconst parent = elementAtPath(root, snapshot.path);\n\t\t\t\tif (parent === null) continue;\n\t\t\t\tconst node = textNodeAt(parent, snapshot.index);\n\t\t\t\tif (node !== undefined && node.data === snapshot.baseline)\n\t\t\t\t\tnode.data = snapshot.translated;\n\t\t\t}\n\t\t\tfor (const snapshot of translatedAttributes) {\n\t\t\t\tconst element = elementAtPath(root, snapshot.path);\n\t\t\t\tif (element?.getAttribute(snapshot.name) === snapshot.baseline)\n\t\t\t\t\telement.setAttribute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AA,IACL,WAAW,YAAY,YAAY;AAAA,MAClC,MAAM,SAAS,cAAc,MAAM,SAAS,IAAI;AAAA,MAChD,IAAI,WAAW;AAAA,QAAM;AAAA,MACrB,MAAM,OAAO,WAAW,QAAQ,SAAS,KAAK;AAAA,MAC9C,IAAI,SAAS,aAAa,KAAK,SAAS,SAAS;AAAA,QAChD,KAAK,OAAO,SAAS;AAAA,IACvB;AAAA,IACA,WAAW,YAAY,sBAAsB;AAAA,MAC5C,MAAM,UAAU,cAAc,MAAM,SAAS,IAAI;AAAA,MACjD,IAAI,SAAS,aAAa,SAAS,IAAI,MAAM,SAAS;AAAA,QACrD,QAAQ,aAAa,SAAS,MAAM,SAAS,UAAU;AAAA,IACzD;AAAA,KAED,WAAW,SAAS,KAAK,qBAAqB,SAAS,CACxD;AAAA;",
|
|
8
|
+
"debugId": "2B49FE79D0C510E564756E2164756E21",
|
|
9
|
+
"names": []
|
|
10
|
+
}
|
|
@@ -0,0 +1,12 @@
|
|
|
1
|
+
// src/client/browserTranslationAttributes.ts
|
|
2
|
+
var TRANSLATABLE_ATTRIBUTES = [
|
|
3
|
+
"alt",
|
|
4
|
+
"title",
|
|
5
|
+
"placeholder",
|
|
6
|
+
"aria-label"
|
|
7
|
+
];
|
|
8
|
+
|
|
9
|
+
export { TRANSLATABLE_ATTRIBUTES };
|
|
10
|
+
|
|
11
|
+
//# debugId=4CF889867CFAFA1F64756E2164756E21
|
|
12
|
+
//# sourceMappingURL=index-jrcwp722.js.map
|
|
@@ -0,0 +1,10 @@
|
|
|
1
|
+
{
|
|
2
|
+
"version": 3,
|
|
3
|
+
"sources": ["../src/client/browserTranslationAttributes.ts"],
|
|
4
|
+
"sourcesContent": [
|
|
5
|
+
"/** Human-readable attributes a browser translator may rewrite before hydration. */\nexport const TRANSLATABLE_ATTRIBUTES = [\n\t'alt',\n\t'title',\n\t'placeholder',\n\t'aria-label'\n] as const;\n"
|
|
6
|
+
],
|
|
7
|
+
"mappings": ";AACO,IAAM,0BAA0B;AAAA,EACtC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD;",
|
|
8
|
+
"debugId": "4CF889867CFAFA1F64756E2164756E21",
|
|
9
|
+
"names": []
|
|
10
|
+
}
|
|
@@ -1,3 +1,6 @@
|
|
|
1
|
+
import {
|
|
2
|
+
TRANSLATABLE_ATTRIBUTES
|
|
3
|
+
} from "./index-jrcwp722.js";
|
|
1
4
|
import {
|
|
2
5
|
isDevelopmentRuntime,
|
|
3
6
|
isProductionRuntime,
|
|
@@ -81,7 +84,7 @@ if (typeof globalThis !== "undefined") {
|
|
|
81
84
|
}
|
|
82
85
|
|
|
83
86
|
// src/core/browserTranslation.ts
|
|
84
|
-
var BROWSER_TRANSLATION_BASELINE_SCRIPT = "window.__ABSOLUTE_SSR_TEXT_BASELINES__=new WeakMap();" + "{const r=document.body,b=window.__ABSOLUTE_SSR_TEXT_BASELINES__;" + 'if(r)for(const e of [r,...r.querySelectorAll("*")]){' + "const t=new Map();for(const [i,n]of[...e.childNodes].entries())" + 'if(n.nodeType===3)t.set(i,n.nodeValue??"");if(t.size)b.set(e,t);}}
|
|
87
|
+
var BROWSER_TRANSLATION_BASELINE_SCRIPT = "window.__ABSOLUTE_SSR_TEXT_BASELINES__=new WeakMap();" + "window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__=new WeakMap();" + "{const r=document.body,b=window.__ABSOLUTE_SSR_TEXT_BASELINES__," + "a=window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__;" + 'if(r)for(const e of [r,...r.querySelectorAll("*")]){' + "const t=new Map();for(const [i,n]of[...e.childNodes].entries())" + 'if(n.nodeType===3)t.set(i,n.nodeValue??"");if(t.size)b.set(e,t);' + `const v=new Map();for(const k of ${JSON.stringify(TRANSLATABLE_ATTRIBUTES)}){` + "const s=e.getAttribute(k);if(s!==null)v.set(k,s);}if(v.size)a.set(e,v);}}";
|
|
85
88
|
|
|
86
89
|
// src/angular/ssrRender.ts
|
|
87
90
|
var routeContextCache = new Map;
|
|
@@ -277,5 +280,5 @@ export {
|
|
|
277
280
|
renderAngularIslandToHtml
|
|
278
281
|
};
|
|
279
282
|
|
|
280
|
-
//# debugId=
|
|
281
|
-
//# sourceMappingURL=islands-
|
|
283
|
+
//# debugId=718D23D8BE97A0B064756E2164756E21
|
|
284
|
+
//# sourceMappingURL=islands-50dg63j9.js.map
|
|
@@ -4,11 +4,11 @@
|
|
|
4
4
|
"sourcesContent": [
|
|
5
5
|
"import type { AngularDeps } from '../../types/angular';\nimport { resolveAngularRuntimePath } from './resolveAngularPackage';\nimport {\n\tisDevelopmentRuntime,\n\tisProductionRuntime\n} from '../utils/runtimeMode';\n\nconst initDominoAdapter = (platformServer: {\n\tɵDominoAdapter?: { makeCurrent?: () => void };\n}) => {\n\ttry {\n\t\tplatformServer.ɵDominoAdapter?.makeCurrent?.();\n\t} catch (err) {\n\t\tconsole.error('Failed to initialize DominoAdapter:', err);\n\t}\n};\n\nconst loadAngularDeps = async () => {\n\t// JIT compiler is only needed in development, where user pages are\n\t// runtime-compiled by `compileAngularFileJIT` and emit partial\n\t// declarations that need the compiler facade to link. In production\n\t// the linker has already processed every partial declaration into\n\t// final ɵdir/ɵcmp/ɵfac at vendor build time, so the compiler isn't\n\t// imported and isn't part of the prod vendor bundle.\n\tif (!isProductionRuntime()) {\n\t\t// Bare specifier in dev — Bun's module cache dedupes on\n\t\t// normalized specifier, so this is the same instance as the\n\t\t// `import \"@angular/compiler\"` baked into bundled server pages.\n\t\tawait import('@angular/compiler');\n\t}\n\n\t// angularPatch imports @angular/platform-server internally, so it\n\t// must also run after the compiler is available.\n\tconst { applyPatches } = await import('./angularPatch');\n\tawait applyPatches();\n\n\t// In dev (no Angular server vendor on disk — see §1.1), use bare\n\t// specifiers so Bun resolves them through node_modules and shares\n\t// the same module records with the bundled server pages, which\n\t// also have bare `@angular/*` imports in dev. Production keeps the\n\t// resolved-path import because the vendor bundle is what every\n\t// server-side import points at, and the resolved path is stable.\n\tconst useBareSpecifiers = !isProductionRuntime();\n\tconst [platformBrowser, platformServer, common, core] = await Promise.all([\n\t\timport(\n\t\t\tuseBareSpecifiers\n\t\t\t\t? '@angular/platform-browser'\n\t\t\t\t: resolveAngularRuntimePath('@angular/platform-browser')\n\t\t),\n\t\timport(\n\t\t\tuseBareSpecifiers\n\t\t\t\t? '@angular/platform-server'\n\t\t\t\t: resolveAngularRuntimePath('@angular/platform-server')\n\t\t),\n\t\timport(\n\t\t\tuseBareSpecifiers\n\t\t\t\t? '@angular/common'\n\t\t\t\t: resolveAngularRuntimePath('@angular/common')\n\t\t),\n\t\timport(\n\t\t\tuseBareSpecifiers\n\t\t\t\t? '@angular/core'\n\t\t\t\t: resolveAngularRuntimePath('@angular/core')\n\t\t)\n\t]);\n\n\tif (!isDevelopmentRuntime()) {\n\t\tcore.enableProdMode();\n\t}\n\n\tinitDominoAdapter(platformServer);\n\n\treturn {\n\t\tAPP_BASE_HREF: common.APP_BASE_HREF,\n\t\tbootstrapApplication: platformBrowser.bootstrapApplication,\n\t\tComponent: core.Component,\n\t\tDomSanitizer: platformBrowser.DomSanitizer,\n\t\tENVIRONMENT_INITIALIZER: core.ENVIRONMENT_INITIALIZER,\n\t\tinject: core.inject,\n\t\tInjectionToken: core.InjectionToken,\n\t\tNgComponentOutlet: common.NgComponentOutlet,\n\t\tprovideClientHydration: platformBrowser.provideClientHydration,\n\t\tprovideServerRendering: platformServer.provideServerRendering,\n\t\tprovideZonelessChangeDetection: core.provideZonelessChangeDetection,\n\t\treflectComponentType: core.reflectComponentType,\n\t\trenderApplication: platformServer.renderApplication,\n\t\tREQUEST: core.REQUEST,\n\t\tREQUEST_CONTEXT: core.REQUEST_CONTEXT,\n\t\tRESPONSE_INIT: core.RESPONSE_INIT,\n\t\tSanitizer: core.Sanitizer,\n\t\tSecurityContext: core.SecurityContext,\n\t\twithHttpTransferCacheOptions:\n\t\t\tplatformBrowser.withHttpTransferCacheOptions\n\t};\n};\n\nlet angularDeps: Promise<AngularDeps> | null = null;\n\nexport const getAngularDeps = () => {\n\tif (!angularDeps) {\n\t\tangularDeps = loadAngularDeps();\n\t}\n\n\treturn angularDeps;\n};\n\n// TODO(test): the unit-style coverage in\n// `tests/integration/angular/single-core.test.ts` checks that\n// `resolveAngularRuntimePath` is consistent across calls and that two\n// dynamic imports from the resolved path return the same module record\n// — necessary but not sufficient. A stronger test would spawn a dev\n// server, trigger an HMR cycle, and assert the SSR process never sees\n// two `@angular/core` evaluations (e.g. via a marker incremented at\n// module init in a vendor stub). The fixture in\n// `tests/fixtures/compile-angular` is wired for compile-time checks\n// only, so end-to-end verification of the SSR core uniqueness fix\n// happens manually in `~/onspark/absolutejs/dealroom` (see\n// docs/ABSOLUTEJS_ANGULAR_HMR.md §3.9).\n",
|
|
6
6
|
"/**\n * Utility for registering client-side scripts that need to run after Angular SSR hydration.\n *\n * This is necessary because Angular's lifecycle hooks don't always run reliably on the client\n * after SSR hydration, especially for event listeners attached to DOM elements.\n *\n * Usage in Angular components:\n * ```typescript\n * import { registerClientScript } from '@absolutejs/absolute';\n *\n * // Register an event listener script\n * registerClientScript(() => {\n * const element = document.querySelector('.my-element');\n * if (element) {\n * element.addEventListener('click', () => {\n * console.log('Clicked!');\n * });\n * }\n * });\n * ```\n *\n * The script will be automatically injected into the HTML response and executed on the client.\n */\n\n// Request-scoped registry for client scripts\n// Each request gets its own set of scripts to inject\nconst scriptRegistry = new Map<string, Set<() => void>>();\n\n// Generate a unique request ID for tracking scripts per request\nlet requestCounter = 0;\nconst getRequestId = () => `req_${Date.now()}_${++requestCounter}`;\n\n// Allow SSR frameworks to inject a request context getter (e.g. AsyncLocalStorage)\nlet ssrContextGetter: (() => string | undefined) | null = null;\nexport const getSsrContextId = () =>\n\tssrContextGetter?.() ||\n\tObject.getOwnPropertyDescriptor(globalThis, '__absolutejs_requestId')\n\t\t?.value;\nexport const registerClientScript = (\n\tscript: () => void,\n\trequestId?: string\n) => {\n\t// Try to get requestId from explicit arg, then Async Context, then global fallback\n\tconst id = requestId || getSsrContextId() || getRequestId();\n\n\tif (!scriptRegistry.has(id)) {\n\t\tscriptRegistry.set(id, new Set());\n\t}\n\n\tscriptRegistry.get(id)?.add(script);\n\n\treturn id;\n};\nexport const setSsrContextGetter = (getter: () => string | undefined) => {\n\tssrContextGetter = getter;\n};\n\n// Make registerClientScript available globally during SSR for Angular components\n// Using type assertion for globalThis extension\nif (typeof globalThis !== 'undefined') {\n\tObject.assign(globalThis, { registerClientScript });\n}\n\n/**\n * Get all registered scripts for a request and clear them.\n * This is called by the page handler after rendering.\n *\n * @param requestId - The request ID to get scripts for\n * @returns Array of script functions, or empty array if none registered\n */\nexport const clearAllClientScripts = () => {\n\tscriptRegistry.clear();\n};\nexport const generateClientScriptCode = (scripts: (() => void)[]) => {\n\tif (scripts.length === 0) {\n\t\treturn '';\n\t}\n\n\t// Convert functions to strings and wrap in IIFE\n\tconst scriptCode = scripts\n\t\t.map((script, index) => {\n\t\t\t// Get the function body as a string\n\t\t\tconst funcString = script.toString();\n\n\t\t\t// Extract the body (everything between { and })\n\t\t\tconst bodyMatch = funcString.match(/\\{([\\s\\S]*)\\}/);\n\t\t\tif (!bodyMatch || !bodyMatch[1]) {\n\t\t\t\treturn '';\n\t\t\t}\n\n\t\t\tconst body = bodyMatch[1].trim();\n\n\t\t\t// Wrap in IIFE with MutationObserver for DOM readiness\n\t\t\treturn `\n\t(function() {\n\t\tvar executed = false;\n\t\tfunction executeScript_${index}() {\n\t\t\tif (executed) return;\n\t\t\texecuted = true;\n\t\t\t${body}\n\t\t}\n\n\t\tif (document.readyState === 'complete' || document.readyState === 'interactive') {\n\t\t\texecuteScript_${index}();\n\t\t} else {\n\t\t\tdocument.addEventListener('DOMContentLoaded', executeScript_${index});\n\t\t}\n\n\t\t// Watch for hydration-added elements\n\t\tvar observer = new MutationObserver(function() {\n\t\t\texecuteScript_${index}();\n\t\t\tif (executed) observer.disconnect();\n\t\t});\n\t\tif (!executed) {\n\t\t\tobserver.observe(document.body || document.documentElement, { childList: true, subtree: true });\n\t\t}\n\n\t\t// Single fallback timeout\n\t\tsetTimeout(function() {\n\t\t\texecuteScript_${index}();\n\t\t\tobserver.disconnect();\n\t\t}, 1000);\n\t})();`;\n\t\t})\n\t\t.join('\\n');\n\n\treturn `<script>\n(function() {\n${scriptCode}\n})();\n</script>`;\n};\nexport const getAndClearClientScripts = (requestId?: string) => {\n\tconst id = requestId || ssrContextGetter?.();\n\tif (!id) return [];\n\n\tconst scripts = scriptRegistry.get(id);\n\tif (!scripts) {\n\t\treturn [];\n\t}\n\n\tconst scriptArray = Array.from(scripts);\n\tscriptRegistry.delete(id);\n\n\treturn scriptArray;\n};\n",
|
|
7
|
-
"
|
|
7
|
+
"import { TRANSLATABLE_ATTRIBUTES } from '../client/browserTranslationAttributes';\n\nconst BASELINE_MARKER = '__ABSOLUTE_SSR_TEXT_BASELINES__';\n\n/** Inline this after SSR markup and before any client entry executes. The\n * snapshot records server-authored text while keeping it out of the DOM, so\n * browser translation remains free to edit the rendered text. */\nexport const BROWSER_TRANSLATION_BASELINE_SCRIPT =\n\t'window.__ABSOLUTE_SSR_TEXT_BASELINES__=new WeakMap();' +\n\t'window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__=new WeakMap();' +\n\t'{const r=document.body,b=window.__ABSOLUTE_SSR_TEXT_BASELINES__,' +\n\t'a=window.__ABSOLUTE_SSR_ATTRIBUTE_BASELINES__;' +\n\t'if(r)for(const e of [r,...r.querySelectorAll(\"*\")]){' +\n\t'const t=new Map();for(const [i,n]of[...e.childNodes].entries())' +\n\t'if(n.nodeType===3)t.set(i,n.nodeValue??\"\");if(t.size)b.set(e,t);' +\n\t`const v=new Map();for(const k of ${JSON.stringify(TRANSLATABLE_ATTRIBUTES)}){` +\n\t'const s=e.getAttribute(k);if(s!==null)v.set(k,s);}if(v.size)a.set(e,v);}}';\n\nexport const browserTranslationBaselineTag = () =>\n\t`<script>${BROWSER_TRANSLATION_BASELINE_SCRIPT}</script>`;\n\nexport const injectBrowserTranslationBaseline = (html: string) => {\n\tif (html.includes(BASELINE_MARKER)) return html;\n\tconst script = browserTranslationBaselineTag();\n\tconst closingBodyIndex = html.lastIndexOf('</body>');\n\tif (closingBodyIndex < 0) return `${html}${script}`;\n\n\treturn `${html.slice(0, closingBodyIndex)}${script}${html.slice(closingBodyIndex)}`;\n};\n",
|
|
8
8
|
"import type { EnvironmentProviders, Provider, Type } from '@angular/core';\nimport type { BootstrapContext } from '@angular/platform-browser';\nimport type { AngularDeps, CachedRouteData } from '../../types/angular';\nimport {\n\tgetAndClearClientScripts,\n\tgenerateClientScriptCode\n} from '../utils/registerClientScript';\nimport { browserTranslationBaselineTag } from '../core/browserTranslation';\nimport { buildAbsoluteHttpTransferCacheOptions } from './httpTransferCache';\nimport { buildRequestProviders } from './requestProviders';\n\n// --- Last-used requestContext cache for HMR ---\n// Stores { requestContext, headTag } from the most recent real request per\n// route so HMR re-renders with the same data the user last saw.\n\nconst routeContextCache = new Map<string, CachedRouteData>();\n\nexport const cacheRouteData = (pagePath: string, data: CachedRouteData) => {\n\tconst cacheKey = pagePath.split('?')[0] ?? pagePath;\n\trouteContextCache.set(cacheKey, data);\n};\nexport const getCachedRouteData = (pagePath: string) =>\n\trouteContextCache.get(pagePath);\n\n// --- Selector cache ---\n\nconst selectorCache = new Map<string, string>();\nexport const buildProviders = (\n\tdeps: AngularDeps,\n\tsanitizer: InstanceType<AngularDeps['DomSanitizer']>,\n\trequest: Request | undefined,\n\trequestContext: unknown,\n\tresponseInit: ResponseInit | undefined,\n\tuserProviders: ReadonlyArray<Provider | EnvironmentProviders> = []\n) => [\n\tdeps.provideServerRendering(),\n\tdeps.provideClientHydration(\n\t\tdeps.withHttpTransferCacheOptions(\n\t\t\tbuildAbsoluteHttpTransferCacheOptions()\n\t\t)\n\t),\n\tdeps.provideZonelessChangeDetection(),\n\t{ provide: deps.APP_BASE_HREF, useValue: '/' },\n\t{ provide: deps.DomSanitizer, useValue: sanitizer },\n\t{ provide: deps.Sanitizer, useValue: sanitizer },\n\t...buildRequestProviders(deps, request, requestContext, responseInit),\n\t...userProviders\n];\nexport const clearSelectorCache = () => selectorCache.clear();\n\nexport const resolveSelector = (\n\tdeps: AngularDeps,\n\tpagePath: string,\n\tPageComponent: Type<unknown>\n) => {\n\tconst cached = selectorCache.get(pagePath);\n\tif (cached) {\n\t\treturn cached;\n\t}\n\n\tconst selector =\n\t\tdeps.reflectComponentType(PageComponent)?.selector ?? 'ng-app';\n\tselectorCache.set(pagePath, selector);\n\n\treturn selector;\n};\n\n// --- Inject HTML helper ---\n\nconst injectBeforeClose = (html: string, snippet: string) => {\n\tif (html.includes('</body>')) {\n\t\treturn html.replace('</body>', `${snippet}</body>`);\n\t}\n\tif (html.includes('</html>')) {\n\t\treturn html.replace('</html>', `${snippet}</html>`);\n\t}\n\n\treturn html + snippet;\n};\n\n// --- Post-render HTML injection ---\n\nexport const injectSsrScripts = (\n\thtml: string,\n\trequestId: string,\n\tindexPath: string,\n\trequestContext?: unknown\n) => {\n\tlet result = injectBeforeClose(html, browserTranslationBaselineTag());\n\n\tconst registeredScripts = getAndClearClientScripts(requestId);\n\tif (registeredScripts.length > 0) {\n\t\tresult = injectBeforeClose(\n\t\t\tresult,\n\t\t\tgenerateClientScriptCode(registeredScripts)\n\t\t);\n\t}\n\n\tif (requestContext !== undefined) {\n\t\tresult = injectBeforeClose(\n\t\t\tresult,\n\t\t\t`<script>window.__ABS_ANGULAR_REQUEST_CONTEXT__ = ${JSON.stringify(requestContext)};</script>`\n\t\t);\n\t}\n\n\tif (indexPath) {\n\t\tconst escapedIndexPath = JSON.stringify(indexPath);\n\t\tresult = injectBeforeClose(\n\t\t\tresult,\n\t\t\t`<script>import(${escapedIndexPath});</script>`\n\t\t);\n\t}\n\n\treturn result;\n};\nexport const renderAngularApp = async (\n\tdeps: AngularDeps,\n\tPageComponent: Type<unknown>,\n\tproviders: (Provider | EnvironmentProviders)[],\n\tdocument: string | Document,\n\turl: string = '/'\n) => {\n\tconst bootstrap = (context: BootstrapContext) =>\n\t\tdeps.bootstrapApplication(PageComponent, { providers }, context);\n\n\treturn withSuppressedAngularDevLogs(() =>\n\t\tdeps.renderApplication(bootstrap, {\n\t\t\tdocument,\n\t\t\tplatformProviders: [],\n\t\t\turl\n\t\t})\n\t);\n};\nexport const withSuppressedAngularDevLogs = async <T>(\n\trender: () => Promise<T>\n) => {\n\tconst origLog = console.log;\n\tconsole.log = (...args: unknown[]) => {\n\t\tif (\n\t\t\ttypeof args[0] === 'string' &&\n\t\t\targs[0].includes('development mode')\n\t\t) {\n\t\t\treturn;\n\t\t}\n\t\torigLog.apply(console, args);\n\t};\n\n\ttry {\n\t\treturn await render();\n\t} finally {\n\t\tconsole.log = origLog;\n\t}\n};\n",
|
|
9
9
|
"import { getAngularDeps } from './angularDeps';\nimport { withSuppressedAngularDevLogs } from './ssrRender';\nimport { getSsrContextId } from '../utils/registerClientScript';\n\nconst angularIslandSelector = 'abs-angular-island';\n\nexport const getAngularIslandSelector = (_islandId: string) =>\n\tangularIslandSelector;\nexport const isAngularComponent = (\n\tvalue: unknown\n): value is import('@angular/core').Type<object> => typeof value === 'function';\n\nconst getSelectorFromRenderedIsland = (rootElement: HTMLElement) => {\n\tconst firstChild = rootElement.firstElementChild;\n\tif (!(firstChild instanceof HTMLElement)) {\n\t\treturn null;\n\t}\n\n\tconst selector = firstChild.tagName.toLowerCase();\n\n\treturn selector.length > 0 ? selector : null;\n};\n\nconst getClientAngularComponentSelector = (\n\tcomponent: import('@angular/core').Type<object>\n) => {\n\tconst maybeDef = Reflect.get(component, 'ɵcmp');\n\tif (typeof maybeDef !== 'object' || maybeDef === null) {\n\t\treturn null;\n\t}\n\n\tconst maybeSelectors = Reflect.get(maybeDef, 'selectors');\n\tif (!Array.isArray(maybeSelectors)) {\n\t\treturn null;\n\t}\n\n\tconst [firstSelectorGroup] = maybeSelectors;\n\tif (!Array.isArray(firstSelectorGroup)) {\n\t\treturn null;\n\t}\n\n\tconst [selector] = firstSelectorGroup;\n\n\treturn typeof selector === 'string' && selector.length > 0\n\t\t? selector\n\t\t: null;\n};\n\nconst createAngularIslandApp = async () => {\n\tconst { EnvironmentInjector, provideZonelessChangeDetection } =\n\t\tawait import('@angular/core');\n\tconst { createApplication } = await import('@angular/platform-browser');\n\tconst app = await createApplication({\n\t\tproviders: [provideZonelessChangeDetection()]\n\t});\n\tconst environmentInjector = app.injector.get(EnvironmentInjector);\n\n\treturn { app, environmentInjector };\n};\n\nlet angularIslandAppPromise: Promise<{\n\tapp: import('@angular/core').ApplicationRef;\n\tenvironmentInjector: import('@angular/core').EnvironmentInjector;\n}> | null = null;\n\nconst getAngularIslandApp = async () => {\n\tif (!angularIslandAppPromise) {\n\t\tangularIslandAppPromise = createAngularIslandApp();\n\t}\n\n\treturn angularIslandAppPromise;\n};\n\ntype AngularIslandWrapperMetadata = {\n\tdeps: Awaited<ReturnType<typeof getAngularDeps>>;\n\tpropsToken: import('@angular/core').InjectionToken<Record<string, unknown>>;\n\tselector: string;\n\tWrapperComponent: import('@angular/core').Type<object>;\n};\n\nconst wrapperMetadataCache = new Map<\n\tstring,\n\tPromise<AngularIslandWrapperMetadata>\n>();\nconst requestRenderCache = new Map<string, Map<string, string>>();\n\nconst getRequestRenderCache = () => {\n\tconst requestId = getSsrContextId();\n\tif (!requestId) {\n\t\treturn null;\n\t}\n\n\tconst cached = requestRenderCache.get(requestId);\n\tif (cached) {\n\t\treturn cached;\n\t}\n\n\tconst renderCache = new Map<string, string>();\n\trequestRenderCache.set(requestId, renderCache);\n\n\treturn renderCache;\n};\n\nconst getAngularIslandWrapperKey = (\n\tcomponent: import('@angular/core').Type<object>,\n\t_islandId: string\n) => {\n\tconst componentName =\n\t\ttypeof component.name === 'string' && component.name.length > 0\n\t\t\t? component.name\n\t\t\t: 'AngularIsland';\n\n\treturn `${componentName}:${angularIslandSelector}`;\n};\n\nconst getIslandRenderCacheKey = (\n\tcomponent: import('@angular/core').Type<object>,\n\tprops: Record<string, unknown>\n) => {\n\tconst componentName =\n\t\ttypeof component.name === 'string' && component.name.length > 0\n\t\t\t? component.name\n\t\t\t: 'AngularIsland';\n\n\treturn `${componentName}:${JSON.stringify(props)}`;\n};\n\nconst buildAngularIslandWrapperMetadata = async (\n\tcomponent: import('@angular/core').Type<object>,\n\tislandId: string,\n\twrapperKey: string\n) => {\n\t// Resolve Angular through getAngularDeps so the wrapper is built with the\n\t// SAME Angular instance that renders it. In production server-side imports\n\t// point at the pre-linked Angular vendor bundle; bare `@angular/*` imports\n\t// here would instead resolve to node_modules, giving the wrapper component\n\t// (its decorator, InjectionToken and inject) a different Angular instance\n\t// than the render pipeline's injector — every cross-instance token lookup\n\t// then fails with NG0201. (Dev uses a single node_modules Angular, so this\n\t// only manifests in production.)\n\tconst deps = await getAngularDeps();\n\tconst { Component, InjectionToken, NgComponentOutlet, inject } = deps;\n\tconst selector = getAngularIslandSelector(islandId);\n\tconst propsToken = new InjectionToken<Record<string, unknown>>(\n\t\t`${wrapperKey}:props`\n\t);\n\n\tclass AngularIslandWrapperComponent {\n\t\tcomponent = component;\n\t\tprops = inject(propsToken);\n\t}\n\n\treturn {\n\t\tdeps,\n\t\tpropsToken,\n\t\tselector,\n\t\tWrapperComponent: Component({\n\t\t\timports: [NgComponentOutlet, component],\n\t\t\tselector,\n\t\t\tstandalone: true,\n\t\t\ttemplate:\n\t\t\t\t'<ng-container *ngComponentOutlet=\"component; inputs: props\"></ng-container>'\n\t\t})(AngularIslandWrapperComponent)\n\t};\n};\n\nconst createAngularIslandWrapper = async (\n\tcomponent: import('@angular/core').Type<object>,\n\tislandId: string\n) => {\n\tconst wrapperKey = getAngularIslandWrapperKey(component, islandId);\n\tconst cached = wrapperMetadataCache.get(wrapperKey);\n\tif (cached) {\n\t\treturn cached;\n\t}\n\n\tconst metadataPromise = buildAngularIslandWrapperMetadata(\n\t\tcomponent,\n\t\tislandId,\n\t\twrapperKey\n\t);\n\n\twrapperMetadataCache.set(wrapperKey, metadataPromise);\n\n\treturn metadataPromise;\n};\n\nconst extractAngularIslandRoot = (html: string, selector: string) => {\n\tconst openTag = `<${selector}`;\n\tconst start = html.indexOf(openTag);\n\tif (start < 0) {\n\t\tthrow new Error(`Could not find Angular island root \"${selector}\".`);\n\t}\n\n\tconst endTag = `</${selector}>`;\n\tconst end = html.indexOf(endTag, start);\n\tif (end < 0) {\n\t\tthrow new Error(`Could not close Angular island root \"${selector}\".`);\n\t}\n\n\treturn html.slice(start, end + endTag.length);\n};\n\nexport const mountAngularIsland = async <Props extends Record<string, unknown>>(\n\tcomponent: import('@angular/core').Type<object>,\n\telement: HTMLElement,\n\tprops: Props,\n\tislandId: string\n) => {\n\tawait import('@angular/compiler');\n\tconst { createComponent, inputBinding } = await import('@angular/core');\n\tconst selector = getAngularIslandSelector(islandId);\n\tconst { app, environmentInjector } = await getAngularIslandApp();\n\n\tlet rootElement = element.querySelector(selector);\n\tif (!(rootElement instanceof HTMLElement)) {\n\t\telement.innerHTML = `<${selector}></${selector}>`;\n\t\trootElement = element.querySelector(selector);\n\t}\n\tif (!(rootElement instanceof HTMLElement)) return app;\n\n\tconst componentSelector =\n\t\tgetClientAngularComponentSelector(component) ??\n\t\tgetSelectorFromRenderedIsland(rootElement);\n\tif (!componentSelector) return app;\n\n\trootElement.innerHTML = `<${componentSelector}></${componentSelector}>`;\n\tconst hostElement = rootElement.querySelector(componentSelector);\n\tif (!(hostElement instanceof HTMLElement)) return app;\n\n\tconst bindings = Object.entries(props).map(([key, value]) =>\n\t\tinputBinding(key, () => value)\n\t);\n\tconst componentRef = createComponent(component, {\n\t\tbindings,\n\t\tenvironmentInjector,\n\t\thostElement\n\t});\n\tapp.attachView(componentRef.hostView);\n\tcomponentRef.changeDetectorRef.detectChanges();\n\twindow.__ABS_ANGULAR_ISLAND_APPS__ ??= [];\n\twindow.__ABS_ANGULAR_ISLAND_APPS__.push(app);\n\n\treturn app;\n};\nexport const renderAngularIslandToHtml = async <\n\tProps extends Record<string, unknown>\n>(\n\tcomponent: import('@angular/core').Type<object>,\n\tprops: Props,\n\tislandId: string\n) => {\n\tconst requestCache = getRequestRenderCache();\n\tconst renderCacheKey = getIslandRenderCacheKey(component, props);\n\tconst cachedHtml = requestCache?.get(renderCacheKey);\n\tif (cachedHtml) {\n\t\treturn cachedHtml;\n\t}\n\n\tconst { deps, propsToken, selector, WrapperComponent } =\n\t\tawait createAngularIslandWrapper(component, islandId);\n\n\tconst providers: (\n\t\t| import('@angular/core').Provider\n\t\t| import('@angular/core').EnvironmentProviders\n\t)[] = [\n\t\tdeps.provideServerRendering(),\n\t\tdeps.provideZonelessChangeDetection(),\n\t\t{ provide: deps.APP_BASE_HREF, useValue: '/' },\n\t\t{ provide: propsToken, useValue: props }\n\t];\n\tconst document = `<!DOCTYPE html><html><body><${selector}></${selector}></body></html>`;\n\tconst html = await withSuppressedAngularDevLogs(() =>\n\t\tdeps.renderApplication(\n\t\t\t(context) =>\n\t\t\t\tdeps.bootstrapApplication(\n\t\t\t\t\tWrapperComponent,\n\t\t\t\t\t{ providers },\n\t\t\t\t\tcontext\n\t\t\t\t),\n\t\t\t{\n\t\t\t\tdocument,\n\t\t\t\tplatformProviders: [],\n\t\t\t\turl: '/'\n\t\t\t}\n\t\t)\n\t);\n\tconst islandHtml = extractAngularIslandRoot(html, selector);\n\trequestCache?.set(renderCacheKey, islandHtml);\n\n\treturn islandHtml;\n};\n"
|
|
10
10
|
],
|
|
11
|
-
"mappings": "
|
|
12
|
-
"debugId": "
|
|
11
|
+
"mappings": ";;;;;;;;;;;;;AAOA,IAAM,oBAAoB,CAAC,mBAErB;AAAA,EACL,IAAI;AAAA,IACH,eAAe,gBAAgB,cAAc;AAAA,IAC5C,OAAO,KAAK;AAAA,IACb,QAAQ,MAAM,uCAAuC,GAAG;AAAA;AAAA;AAI1D,IAAM,kBAAkB,YAAY;AAAA,EAOnC,IAAI,CAAC,oBAAoB,GAAG;AAAA,IAI3B,MAAa;AAAA,EACd;AAAA,EAIA,QAAQ,iBAAiB,MAAa;AAAA,EACtC,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index-dk743xs6.js";
|
|
4
|
+
import"./index-jrcwp722.js";
|
|
4
5
|
import"./index-qxjc7kc5.js";
|
|
5
6
|
|
|
6
7
|
// src/client/hydrators/react.ts
|
|
@@ -61,5 +62,5 @@ export {
|
|
|
61
62
|
isReactComponent
|
|
62
63
|
};
|
|
63
64
|
|
|
64
|
-
//# debugId=
|
|
65
|
-
//# sourceMappingURL=react-
|
|
65
|
+
//# debugId=D11DE2271415DC6964756E2164756E21
|
|
66
|
+
//# sourceMappingURL=react-yq4ss9y4.js.map
|
|
@@ -4,7 +4,7 @@
|
|
|
4
4
|
"sourcesContent": [
|
|
5
5
|
"import { type ComponentType, createElement, type ReactNode } from 'react';\nimport { hydrateRoot, type Root as ReactRoot } from 'react-dom/client';\nimport { flushSync } from 'react-dom';\nimport { prepareBrowserTranslationHydration } from '../browserTranslation';\n\nconst reactIslandRoots = new WeakMap<HTMLElement, ReactRoot>();\n\nconst isPropsRecord = (value: unknown): value is Record<string, unknown> =>\n\ttypeof value === 'object' && value !== null;\n\n// The island marker is rendered by the host page's React tree as a\n// `dangerouslySetInnerHTML` boundary, so the host root tags it with internal\n// fiber expandos (`__reactFiber$…`, `__reactProps$…`). React refuses to create\n// a second root on a node it already manages that also sets\n// dangerouslySetInnerHTML (\"Cannot use a ref … as a container … if that element\n// also sets dangerouslySetInnerHTML\"). Detaching those expandos hands ownership\n// of the marker (and its opaque SSR children) to the island root before it\n// hydrates. The host root never recurses into the boundary, so it has no fibers\n// for the children and won't reconcile this subtree again.\nconst HOST_REACT_EXPANDO_PREFIXES = [\n\t'__reactFiber$',\n\t'__reactProps$',\n\t'__reactContainer$',\n\t'__reactEvents$',\n\t'__reactListeners$',\n\t'__reactHandles$'\n];\n\nconst detachFromHostReactRoot = (element: HTMLElement) => {\n\tfor (const key of Object.keys(element)) {\n\t\tconst isHostExpando = HOST_REACT_EXPANDO_PREFIXES.some((prefix) =>\n\t\t\tkey.startsWith(prefix)\n\t\t);\n\t\tif (!isHostExpando) continue;\n\t\tReflect.deleteProperty(element, key);\n\t}\n};\n\nexport const hydrateReactIsland = (\n\tcomponent: ComponentType<Record<string, unknown>>,\n\telement: HTMLElement,\n\tprops: unknown\n) => {\n\tconst existingRoot = reactIslandRoots.get(element);\n\tif (existingRoot) {\n\t\texistingRoot.render(\n\t\t\tisPropsRecord(props)\n\t\t\t\t? createElement(component, props)\n\t\t\t\t: createElement(component)\n\t\t);\n\n\t\treturn;\n\t}\n\n\tdetachFromHostReactRoot(element);\n\tconst restoreTranslation = prepareBrowserTranslationHydration(element);\n\tconst hydrate = (elementToHydrate: ReactNode) => {\n\t\tlet root: ReactRoot | undefined;\n\t\tconst startHydration = () => {\n\t\t\troot = hydrateRoot(element, elementToHydrate);\n\t\t};\n\t\ttry {\n\t\t\tif (restoreTranslation.hasTranslation) flushSync(startHydration);\n\t\t\telse startHydration();\n\t\t} finally {\n\t\t\trestoreTranslation();\n\t\t}\n\t\tif (root !== undefined) reactIslandRoots.set(element, root);\n\t};\n\n\tif (!isPropsRecord(props)) {\n\t\thydrate(createElement(component));\n\n\t\treturn;\n\t}\n\n\thydrate(createElement(component, props));\n};\nexport const isReactComponent = (\n\tvalue: unknown\n): value is ComponentType<Record<string, unknown>> =>\n\ttypeof value === 'function';\n"
|
|
6
6
|
],
|
|
7
|
-
"mappings": "
|
|
8
|
-
"debugId": "
|
|
7
|
+
"mappings": ";;;;;;;AAAA;AACA;AACA;AAGA,IAAM,mBAAmB,IAAI;AAE7B,IAAM,gBAAgB,CAAC,UACtB,OAAO,UAAU,YAAY,UAAU;AAWxC,IAAM,8BAA8B;AAAA,EACnC;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AAAA,EACA;AACD;AAEA,IAAM,0BAA0B,CAAC,YAAyB;AAAA,EACzD,WAAW,OAAO,OAAO,KAAK,OAAO,GAAG;AAAA,IACvC,MAAM,gBAAgB,4BAA4B,KAAK,CAAC,WACvD,IAAI,WAAW,MAAM,CACtB;AAAA,IACA,IAAI,CAAC;AAAA,MAAe;AAAA,IACpB,QAAQ,eAAe,SAAS,GAAG;AAAA,EACpC;AAAA;AAGM,IAAM,qBAAqB,CACjC,WACA,SACA,UACI;AAAA,EACJ,MAAM,eAAe,iBAAiB,IAAI,OAAO;AAAA,EACjD,IAAI,cAAc;AAAA,IACjB,aAAa,OACZ,cAAc,KAAK,IAChB,cAAc,WAAW,KAAK,IAC9B,cAAc,SAAS,CAC3B;AAAA,IAEA;AAAA,EACD;AAAA,EAEA,wBAAwB,OAAO;AAAA,EAC/B,MAAM,qBAAqB,mCAAmC,OAAO;AAAA,EACrE,MAAM,UAAU,CAAC,qBAAgC;AAAA,IAChD,IAAI;AAAA,IACJ,MAAM,iBAAiB,MAAM;AAAA,MAC5B,OAAO,YAAY,SAAS,gBAAgB;AAAA;AAAA,IAE7C,IAAI;AAAA,MACH,IAAI,mBAAmB;AAAA,QAAgB,UAAU,cAAc;AAAA,MAC1D;AAAA,uBAAe;AAAA,cACnB;AAAA,MACD,mBAAmB;AAAA;AAAA,IAEpB,IAAI,SAAS;AAAA,MAAW,iBAAiB,IAAI,SAAS,IAAI;AAAA;AAAA,EAG3D,IAAI,CAAC,cAAc,KAAK,GAAG;AAAA,IAC1B,QAAQ,cAAc,SAAS,CAAC;AAAA,IAEhC;AAAA,EACD;AAAA,EAEA,QAAQ,cAAc,WAAW,KAAK,CAAC;AAAA;AAEjC,IAAM,mBAAmB,CAC/B,UAEA,OAAO,UAAU;",
|
|
8
|
+
"debugId": "D11DE2271415DC6964756E2164756E21",
|
|
9
9
|
"names": []
|
|
10
10
|
}
|
package/dist/client/index.js
CHANGED
|
@@ -1,7 +1,8 @@
|
|
|
1
1
|
import {
|
|
2
2
|
captureSsrTextBaselines,
|
|
3
3
|
prepareBrowserTranslationHydration
|
|
4
|
-
} from "./chunks/index-
|
|
4
|
+
} from "./chunks/index-dk743xs6.js";
|
|
5
|
+
import"./chunks/index-jrcwp722.js";
|
|
5
6
|
import {
|
|
6
7
|
__require
|
|
7
8
|
} from "./chunks/index-qxjc7kc5.js";
|
|
@@ -342,7 +343,7 @@ var hydratePreservingBrowserTranslation = async (element, hydrate) => {
|
|
|
342
343
|
var hydrateByFramework = async (registry, framework, componentName, element, props, resolveComponent) => {
|
|
343
344
|
const propsRecord = isPropsRecord(props) ? props : undefined;
|
|
344
345
|
if (framework === "react") {
|
|
345
|
-
const { hydrateReactIsland, isReactComponent } = await import("./chunks/react-
|
|
346
|
+
const { hydrateReactIsland, isReactComponent } = await import("./chunks/react-yq4ss9y4.js");
|
|
346
347
|
const resolvedComponent = await resolveComponent?.(framework, componentName) ?? getIslandComponent(registry.react?.[componentName]);
|
|
347
348
|
if (!isReactComponent(resolvedComponent))
|
|
348
349
|
return;
|
|
@@ -369,7 +370,7 @@ var hydrateByFramework = async (registry, framework, componentName, element, pro
|
|
|
369
370
|
return;
|
|
370
371
|
}
|
|
371
372
|
if (framework === "angular") {
|
|
372
|
-
const { mountAngularIsland, isAngularComponent } = await import("./chunks/islands-
|
|
373
|
+
const { mountAngularIsland, isAngularComponent } = await import("./chunks/islands-50dg63j9.js");
|
|
373
374
|
const resolvedComponent = await resolveComponent?.(framework, componentName) ?? getIslandComponent(registry.angular?.[componentName]);
|
|
374
375
|
const { islandId } = element.dataset;
|
|
375
376
|
if (!isAngularComponent(resolvedComponent) || !islandId)
|
|
@@ -477,5 +478,5 @@ export {
|
|
|
477
478
|
subscribeIslandStore
|
|
478
479
|
};
|
|
479
480
|
|
|
480
|
-
//# debugId=
|
|
481
|
+
//# debugId=7EB687085157DB7464756E2164756E21
|
|
481
482
|
//# sourceMappingURL=index.js.map
|
package/dist/client/index.js.map
CHANGED
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
"import type { RuntimeIslandRenderProps } from '../../types/island';\nimport { getIslandMarkerAttributes } from '../core/islandMarkupAttributes';\n\ntype PreservedIslandMarkup = {\n\tattributes: Record<string, string>;\n\tinnerHTML: string;\n};\n\ntype IslandMarkerElement = HTMLElement & {\n\tdataset: DOMStringMap & {\n\t\tcomponent?: string;\n\t\tframework?: string;\n\t\thydrate?: string;\n\t\tisland?: string;\n\t\tislandId?: string;\n\t\tprops?: string;\n\t};\n};\n\nconst getSnapshotMap = () => {\n\tif (typeof window === 'undefined') {\n\t\treturn null;\n\t}\n\n\twindow.__ABS_SERVER_ISLAND_HTML__ ??= new Map<\n\t\tstring,\n\t\tPreservedIslandMarkup[]\n\t>();\n\n\treturn window.__ABS_SERVER_ISLAND_HTML__;\n};\n\nconst getIslandSignature = (props: RuntimeIslandRenderProps) => {\n\tconst attributes = getIslandMarkerAttributes(props);\n\n\treturn [\n\t\tattributes['data-component'],\n\t\tattributes['data-framework'],\n\t\tattributes['data-hydrate'],\n\t\tattributes['data-props']\n\t].join('::');\n};\n\nconst isMatchingIslandElement = (\n\telement: Element,\n\tprops: RuntimeIslandRenderProps\n): element is IslandMarkerElement => {\n\tif (!(element instanceof HTMLElement)) {\n\t\treturn false;\n\t}\n\n\tconst attributes = getIslandMarkerAttributes(props);\n\n\treturn (\n\t\telement.dataset.island === 'true' &&\n\t\telement.dataset.component === attributes['data-component'] &&\n\t\telement.dataset.framework === attributes['data-framework'] &&\n\t\t(element.dataset.hydrate ?? 'load') === attributes['data-hydrate'] &&\n\t\t(element.dataset.props ?? '{}') === attributes['data-props']\n\t);\n};\n\nconst snapshotIslandElement = (\n\telement: HTMLElement,\n\tsnapshotMap: Map<string, PreservedIslandMarkup[]>\n) => {\n\tconst signature = [\n\t\telement.dataset.component,\n\t\telement.dataset.framework,\n\t\telement.dataset.hydrate ?? 'load',\n\t\telement.dataset.props ?? '{}'\n\t].join('::');\n\tconst existing = snapshotMap.get(signature) ?? [];\n\tconst attributes = Object.fromEntries(\n\t\telement\n\t\t\t.getAttributeNames()\n\t\t\t.map((name) => [name, element.getAttribute(name) ?? ''])\n\t);\n\texisting.push({\n\t\tattributes,\n\t\tinnerHTML: element.innerHTML\n\t});\n\tsnapshotMap.set(signature, existing);\n};\n\nexport const initializeIslandMarkupSnapshot = () => {\n\tif (typeof document === 'undefined') {\n\t\treturn;\n\t}\n\n\tconst snapshotMap = getSnapshotMap();\n\tif (!snapshotMap || snapshotMap.size > 0) {\n\t\treturn;\n\t}\n\n\tconst elements = Array.from(\n\t\tdocument.querySelectorAll<HTMLElement>('[data-island=\"true\"]')\n\t);\n\tfor (const element of elements) {\n\t\tsnapshotIslandElement(element, snapshotMap);\n\t}\n};\n\nexport const preserveIslandMarkup = (props: RuntimeIslandRenderProps) => {\n\tif (typeof document === 'undefined') {\n\t\treturn {\n\t\t\tattributes: getIslandMarkerAttributes(props),\n\t\t\tinnerHTML: ''\n\t\t};\n\t}\n\n\tconst snapshotMap = getSnapshotMap();\n\tconst signature = getIslandSignature(props);\n\t// Islands that share a signature (same component, framework, hydrate mode\n\t// and serialized props) produce byte-identical SSR markup, so the first\n\t// captured snapshot is correct for every instance. Returning it\n\t// unconditionally keeps this stateless: React may call the component many\n\t// times during a single hydration (StrictMode double-render, hydration\n\t// retries, mismatch regeneration), and a per-call claim counter would run\n\t// past the snapshot list and yield empty markup — making the host render\n\t// `dangerouslySetInnerHTML={{ __html: '' }}` and wipe the island's\n\t// server-rendered DOM before the island runtime can hydrate it.\n\tconst snapshotCandidate = snapshotMap?.get(signature)?.[0];\n\tif (snapshotCandidate) {\n\t\treturn snapshotCandidate;\n\t}\n\n\t// Snapshot not captured yet (the island runtime module hasn't evaluated):\n\t// fall back to reading the live SSR DOM directly.\n\tconst liveCandidate = Array.from(\n\t\tdocument.querySelectorAll('[data-island=\"true\"]')\n\t).find((element) => isMatchingIslandElement(element, props));\n\tif (!liveCandidate) {\n\t\treturn {\n\t\t\tattributes: getIslandMarkerAttributes(props),\n\t\t\tinnerHTML: ''\n\t\t};\n\t}\n\n\treturn {\n\t\tattributes: Object.fromEntries(\n\t\t\tliveCandidate\n\t\t\t\t.getAttributeNames()\n\t\t\t\t.map((name) => [name, liveCandidate.getAttribute(name) ?? ''])\n\t\t),\n\t\tinnerHTML: liveCandidate.innerHTML\n\t};\n};\n",
|
|
13
13
|
"import type { IslandFramework } from '../../types/island';\nimport { getIslandComponent, parseIslandProps } from '../core/islands';\nimport { initializeIslandMarkupSnapshot } from './preserveIslandMarkup';\nimport { prepareBrowserTranslationHydration } from './browserTranslation';\n\ninitializeIslandMarkupSnapshot();\n\ntype RuntimeIslandRegistry = Partial<\n\tRecord<IslandFramework, Record<string, unknown>>\n>;\n\ntype StartIslandsOptions = {\n\tregistry: RuntimeIslandRegistry;\n\tresolveComponent?: (\n\t\tframework: IslandFramework,\n\t\tcomponent: string\n\t) => Promise<unknown>;\n\troot?: ParentNode & Node;\n};\n\ntype IslandElement = HTMLElement & {\n\tdataset: DOMStringMap & {\n\t\tcomponent?: string;\n\t\terror?: string;\n\t\tframework?: IslandFramework;\n\t\thydrate?: string;\n\t\tislandId?: string;\n\t\tprops?: string;\n\t};\n};\n\nconst idleDeadline: IdleDeadline = {\n\tdidTimeout: false,\n\ttimeRemaining: () => 0\n};\n\nconst requestIdle =\n\ttypeof window !== 'undefined' && 'requestIdleCallback' in window\n\t\t? window.requestIdleCallback.bind(window)\n\t\t: (callback: IdleRequestCallback) =>\n\t\t\t\twindow.setTimeout(() => callback(idleDeadline), 1);\n\nconst isPropsRecord = (value: unknown): value is Record<string, unknown> =>\n\ttypeof value === 'object' && value !== null;\n\nconst isIslandElement = (value: EventTarget | null): value is IslandElement =>\n\tvalue instanceof HTMLElement && value.dataset.island === 'true';\n\nconst observedRoots = new WeakSet<Node>();\nconst hydratingIslands = new WeakSet<HTMLElement>();\n\nconst hydratePreservingBrowserTranslation = async (\n\telement: HTMLElement,\n\thydrate: () => unknown | Promise<unknown>\n) => {\n\tconst restoreTranslation = prepareBrowserTranslationHydration(element);\n\ttry {\n\t\tawait hydrate();\n\t} finally {\n\t\trestoreTranslation();\n\t}\n};\n\n// Framework-specific hydrators are dynamic-imported on first use so the\n// island runtime never statically pulls in a framework's runtime (and its\n// transitive deps) the consumer doesn't actually use. Without this, a\n// React-only project loading `@absolutejs/absolute/client` would resolve\n// every framework's peer deps — including `@angular/core` — and fail at\n// module load if any of them weren't installed.\nconst hydrateByFramework = async (\n\tregistry: RuntimeIslandRegistry,\n\tframework: IslandFramework,\n\tcomponentName: string,\n\telement: IslandElement,\n\tprops: unknown,\n\tresolveComponent?: (\n\t\tframework: IslandFramework,\n\t\tcomponent: string\n\t) => Promise<unknown>\n) => {\n\tconst propsRecord = isPropsRecord(props) ? props : undefined;\n\n\tif (framework === 'react') {\n\t\tconst { hydrateReactIsland, isReactComponent } = await import(\n\t\t\t'./hydrators/react'\n\t\t);\n\t\tconst resolvedComponent =\n\t\t\t(await resolveComponent?.(framework, componentName)) ??\n\t\t\tgetIslandComponent(registry.react?.[componentName]);\n\t\tif (!isReactComponent(resolvedComponent)) return;\n\n\t\thydrateReactIsland(resolvedComponent, element, propsRecord);\n\t\telement.dataset.hydrated = 'true';\n\n\t\treturn;\n\t}\n\n\tif (framework === 'svelte') {\n\t\tconst { hydrateSvelteIsland, isSvelteComponent } = await import(\n\t\t\t'./hydrators/svelte'\n\t\t);\n\t\tconst resolvedComponent =\n\t\t\t(await resolveComponent?.(framework, componentName)) ??\n\t\t\tgetIslandComponent(registry.svelte?.[componentName]);\n\t\tif (!isSvelteComponent(resolvedComponent)) return;\n\n\t\tawait hydratePreservingBrowserTranslation(element, () =>\n\t\t\thydrateSvelteIsland(resolvedComponent, element, propsRecord)\n\t\t);\n\t\telement.dataset.hydrated = 'true';\n\n\t\treturn;\n\t}\n\n\tif (framework === 'vue') {\n\t\tconst { hydrateVueIsland, isVueComponent } = await import(\n\t\t\t'./hydrators/vue'\n\t\t);\n\t\tconst resolvedComponent =\n\t\t\t(await resolveComponent?.(framework, componentName)) ??\n\t\t\tgetIslandComponent(registry.vue?.[componentName]);\n\t\tif (!isVueComponent(resolvedComponent)) return;\n\n\t\tawait hydratePreservingBrowserTranslation(element, () =>\n\t\t\thydrateVueIsland(resolvedComponent, element, propsRecord)\n\t\t);\n\t\telement.dataset.hydrated = 'true';\n\n\t\treturn;\n\t}\n\n\tif (framework === 'angular') {\n\t\tconst { mountAngularIsland, isAngularComponent } = await import(\n\t\t\t'../angular/islands'\n\t\t);\n\t\tconst resolvedComponent =\n\t\t\t(await resolveComponent?.(framework, componentName)) ??\n\t\t\tgetIslandComponent(registry.angular?.[componentName]);\n\t\tconst { islandId } = element.dataset;\n\t\tif (!isAngularComponent(resolvedComponent) || !islandId) return;\n\n\t\tawait hydratePreservingBrowserTranslation(element, () =>\n\t\t\tmountAngularIsland(\n\t\t\t\tresolvedComponent,\n\t\t\t\telement,\n\t\t\t\tpropsRecord ?? {},\n\t\t\t\tislandId\n\t\t\t)\n\t\t);\n\t\telement.dataset.hydrated = 'true';\n\t}\n};\n\nconst hydrateIsland = async (\n\tregistry: RuntimeIslandRegistry,\n\telement: IslandElement,\n\tresolveComponent?: (\n\t\tframework: IslandFramework,\n\t\tcomponent: string\n\t) => Promise<unknown>\n) => {\n\tif (element.dataset.hydrated === 'true' || hydratingIslands.has(element)) {\n\t\treturn;\n\t}\n\n\tconst { framework } = element.dataset;\n\tconst componentName = element.dataset.component;\n\tif (!framework || !componentName) return;\n\n\tconst props = parseIslandProps(element.getAttribute('data-props'));\n\thydratingIslands.add(element);\n\n\ttry {\n\t\tawait hydrateByFramework(\n\t\t\tregistry,\n\t\t\tframework,\n\t\t\tcomponentName,\n\t\t\telement,\n\t\t\tprops,\n\t\t\tresolveComponent\n\t\t);\n\t} catch (error) {\n\t\tconst message =\n\t\t\terror instanceof Error ? error.message : 'Unknown island error';\n\t\telement.dataset.error = message;\n\t\tconsole.error(\n\t\t\t`[islands] Failed to hydrate ${framework}:${componentName}`,\n\t\t\terror\n\t\t);\n\t} finally {\n\t\thydratingIslands.delete(element);\n\t}\n};\n\nconst scheduleIsland = (\n\tregistry: RuntimeIslandRegistry,\n\telement: IslandElement,\n\tobserver: IntersectionObserver | null,\n\tresolveComponent?: (\n\t\tframework: IslandFramework,\n\t\tcomponent: string\n\t) => Promise<unknown>\n) => {\n\tconst mode = element.dataset.hydrate ?? 'load';\n\tif (mode === 'none') return;\n\tif (mode === 'load') {\n\t\tvoid hydrateIsland(registry, element, resolveComponent);\n\n\t\treturn;\n\t}\n\tif (mode === 'idle') {\n\t\trequestIdle(\n\t\t\t() => void hydrateIsland(registry, element, resolveComponent)\n\t\t);\n\n\t\treturn;\n\t}\n\tif (mode === 'visible' && observer) {\n\t\tobserver.observe(element);\n\n\t\treturn;\n\t}\n\n\tvoid hydrateIsland(registry, element, resolveComponent);\n};\n\nconst collectIslandElements = (node: Node) => {\n\tconst islands: IslandElement[] = [];\n\tif (isIslandElement(node)) islands.push(node);\n\tif (!(node instanceof Element)) return islands;\n\n\tconst nested = node.querySelectorAll<IslandElement>('[data-island=\"true\"]');\n\tfor (const island of nested) {\n\t\tislands.push(island);\n\t}\n\n\treturn islands;\n};\n\nexport const startIslands = ({\n\tregistry,\n\tresolveComponent,\n\troot = document.documentElement\n}: StartIslandsOptions) => {\n\tconst targetRoot = root instanceof Document ? root.documentElement : root;\n\n\tconst observer =\n\t\ttypeof IntersectionObserver === 'undefined'\n\t\t\t? null\n\t\t\t: new IntersectionObserver((entries) => {\n\t\t\t\t\tfor (const entry of entries) {\n\t\t\t\t\t\tif (!entry.isIntersecting) continue;\n\t\t\t\t\t\tif (!isIslandElement(entry.target)) continue;\n\n\t\t\t\t\t\tobserver?.unobserve(entry.target);\n\t\t\t\t\t\tvoid hydrateIsland(\n\t\t\t\t\t\t\tregistry,\n\t\t\t\t\t\t\tentry.target,\n\t\t\t\t\t\t\tresolveComponent\n\t\t\t\t\t\t);\n\t\t\t\t\t}\n\t\t\t\t});\n\n\tconst islands = targetRoot.querySelectorAll<IslandElement>(\n\t\t'[data-island=\"true\"]'\n\t);\n\tfor (const island of islands) {\n\t\tscheduleIsland(registry, island, observer, resolveComponent);\n\t}\n\n\tif (typeof MutationObserver === 'undefined') return;\n\tif (observedRoots.has(targetRoot)) return;\n\n\tconst mutationObserver = new MutationObserver((records) => {\n\t\tconst addedIslands = records.flatMap((record) =>\n\t\t\tArray.from(record.addedNodes).flatMap(collectIslandElements)\n\t\t);\n\t\tfor (const island of addedIslands) {\n\t\t\tscheduleIsland(registry, island, observer, resolveComponent);\n\t\t}\n\t});\n\n\tobservedRoots.add(targetRoot);\n\tmutationObserver.observe(targetRoot, {\n\t\tchildList: true,\n\t\tsubtree: true\n\t});\n};\n"
|
|
14
14
|
],
|
|
15
|
-
"mappings": ";;;;;;;;;AAEA,IAAM,2BAA2B,CAAC,cACjC,UAAU,IAAI,YAAY,IAAI,UAAU,MAAM,CAAC;AAEhD,IAAM,0BAA0B,CAC/B,UACA,WACI;AAAA,EACJ,MAAM,UAAkC,CAAC;AAAA,EACzC,IAAI,QAAQ;AAAA,EAEZ,YAAY,KAAK,UAAU,OAAO,QAAQ,QAAQ,GAAG;AAAA,IACpD,IAAI,CAAC,IAAI,WAAW,MAAM;AAAA,MAAG;AAAA,IAE7B,MAAM,YAAY,IAAI,MAAM,OAAO,MAAM;AAAA,IACzC,IAAI,CAAC;AAAA,MAAW;AAAA,IAEhB,QAAQ,aAAa;AAAA,IACrB,QAAQ;AAAA,EACT;AAAA,EAEA,OAAO,QAAQ,UAAU;AAAA;AAGnB,IAAM,2BAA2B,CAAC,aAAqC;AAAA,EAC7E,MAAM,UACL,CAAC;AAAA,EACF,MAAM,aAAgC,CAAC,SAAS,UAAU,OAAO,SAAS;AAAA,EAE1E,WAAW,aAAa,YAAY;AAAA,IACnC,MAAM,SAAS,SAAS,yBAAyB,SAAS;AAAA,IAC1D,MAAM,UAAU,wBAAwB,UAAU,MAAM;AAAA,IACxD,IAAI;AAAA,MAAS,QAAQ,aAAa;AAAA,EACnC;AAAA,EAEA,OAAO;AAAA;AAED,IAAM,uBAAuB,CACnC,WACA,cACI,SAAS,yBAAyB,SAAS,IAAI;;;ACnC7C,IAAM,+BAA+B,CAC3C,aACI;AAAA,EACJ,MAAM,iBAAiB,yBAAyB,QAAQ;AAAA,EAExD,OA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