@absolutejs/absolute 0.19.0-beta.412 → 0.19.0-beta.414
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/dist/angular/browser.js +21 -12
- package/dist/angular/browser.js.map +3 -3
- package/dist/angular/components/stream-slot.component.js +23 -12
- package/dist/angular/index.js +22 -13
- package/dist/angular/index.js.map +3 -3
- package/dist/angular/server.js +2 -2
- package/dist/angular/server.js.map +1 -1
- package/dist/build.js +2 -2
- package/dist/build.js.map +1 -1
- package/dist/index.js +2 -2
- package/dist/index.js.map +1 -1
- package/dist/src/angular/components/stream-slot.component.d.ts +1 -0
- package/package.json +1 -1
|
@@ -24,23 +24,27 @@ export class StreamSlotComponent {
|
|
|
24
24
|
this.currentHtml = signal('', ...(ngDevMode ? [{ debugName: "currentHtml" }] : /* istanbul ignore next */ []));
|
|
25
25
|
}
|
|
26
26
|
ngOnInit() {
|
|
27
|
-
|
|
28
|
-
|
|
27
|
+
if (typeof window === 'undefined') {
|
|
28
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(this.fallbackHtml));
|
|
29
|
+
registerStreamingSlot({
|
|
30
|
+
errorHtml: this.errorHtml,
|
|
31
|
+
fallbackHtml: this.fallbackHtml,
|
|
32
|
+
id: this.id,
|
|
33
|
+
resolve: this.resolve,
|
|
34
|
+
timeoutMs: this.timeoutMs
|
|
35
|
+
});
|
|
29
36
|
return;
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
34
|
-
|
|
35
|
-
timeoutMs: this.timeoutMs
|
|
36
|
-
});
|
|
37
|
+
}
|
|
38
|
+
const existingHtml = this.readSlotHtml();
|
|
39
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(existingHtml && existingHtml.length > 0
|
|
40
|
+
? existingHtml
|
|
41
|
+
: this.fallbackHtml));
|
|
37
42
|
}
|
|
38
43
|
ngAfterViewInit() {
|
|
39
44
|
if (typeof window === 'undefined')
|
|
40
45
|
return;
|
|
41
46
|
window.addEventListener(SLOT_PATCH_EVENT, this.patchListener);
|
|
42
|
-
const
|
|
43
|
-
const existingHtml = slotElement?.innerHTML;
|
|
47
|
+
const existingHtml = this.readSlotHtml();
|
|
44
48
|
if (existingHtml && existingHtml !== this.fallbackHtml) {
|
|
45
49
|
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(existingHtml));
|
|
46
50
|
this.cdr.markForCheck();
|
|
@@ -51,8 +55,12 @@ export class StreamSlotComponent {
|
|
|
51
55
|
return;
|
|
52
56
|
window.removeEventListener(SLOT_PATCH_EVENT, this.patchListener);
|
|
53
57
|
}
|
|
58
|
+
readSlotHtml() {
|
|
59
|
+
const slotElement = this.hostElement.nativeElement.querySelector(`#slot-${this.id}`);
|
|
60
|
+
return slotElement?.innerHTML ?? '';
|
|
61
|
+
}
|
|
54
62
|
static { this.ɵfac = i0.ɵɵngDeclareFactory({ minVersion: "12.0.0", version: "21.2.6", ngImport: i0, type: StreamSlotComponent, deps: [], target: i0.ɵɵFactoryTarget.Component }); }
|
|
55
|
-
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.6", type: StreamSlotComponent, isStandalone: true, selector: "abs-stream-slot", inputs: { className: "className", errorHtml: "errorHtml", fallbackHtml: "fallbackHtml", id: "id", resolve: "resolve", timeoutMs: "timeoutMs" }, ngImport: i0, template: `
|
|
63
|
+
static { this.ɵcmp = i0.ɵɵngDeclareComponent({ minVersion: "14.0.0", version: "21.2.6", type: StreamSlotComponent, isStandalone: true, selector: "abs-stream-slot", inputs: { className: "className", errorHtml: "errorHtml", fallbackHtml: "fallbackHtml", id: "id", resolve: "resolve", timeoutMs: "timeoutMs" }, host: { attributes: { "ngSkipHydration": "true" } }, ngImport: i0, template: `
|
|
56
64
|
<div
|
|
57
65
|
[attr.id]="'slot-' + id"
|
|
58
66
|
[attr.class]="className"
|
|
@@ -64,6 +72,9 @@ export class StreamSlotComponent {
|
|
|
64
72
|
i0.ɵɵngDeclareClassMetadata({ minVersion: "12.0.0", version: "21.2.6", ngImport: i0, type: StreamSlotComponent, decorators: [{
|
|
65
73
|
type: Component,
|
|
66
74
|
args: [{
|
|
75
|
+
host: {
|
|
76
|
+
ngSkipHydration: 'true'
|
|
77
|
+
},
|
|
67
78
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
68
79
|
selector: 'abs-stream-slot',
|
|
69
80
|
standalone: true,
|
package/dist/angular/index.js
CHANGED
|
@@ -169160,7 +169160,7 @@ ${registrations}
|
|
|
169160
169160
|
({ tsLibDir } = cached);
|
|
169161
169161
|
cached.lastUsed = Date.now();
|
|
169162
169162
|
} else {
|
|
169163
|
-
const tsPath = __require.resolve("
|
|
169163
|
+
const tsPath = __require.resolve("typescript");
|
|
169164
169164
|
const tsRootDir = dirname(tsPath);
|
|
169165
169165
|
tsLibDir = tsRootDir.endsWith("lib") ? tsRootDir : resolve(tsRootDir, "lib");
|
|
169166
169166
|
const config = readConfiguration("./tsconfig.json");
|
|
@@ -181405,23 +181405,25 @@ class StreamSlotComponent {
|
|
|
181405
181405
|
};
|
|
181406
181406
|
currentHtml = signal("");
|
|
181407
181407
|
ngOnInit() {
|
|
181408
|
-
|
|
181409
|
-
|
|
181408
|
+
if (typeof window === "undefined") {
|
|
181409
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(this.fallbackHtml));
|
|
181410
|
+
registerStreamingSlot({
|
|
181411
|
+
errorHtml: this.errorHtml,
|
|
181412
|
+
fallbackHtml: this.fallbackHtml,
|
|
181413
|
+
id: this.id,
|
|
181414
|
+
resolve: this.resolve,
|
|
181415
|
+
timeoutMs: this.timeoutMs
|
|
181416
|
+
});
|
|
181410
181417
|
return;
|
|
181411
|
-
|
|
181412
|
-
|
|
181413
|
-
|
|
181414
|
-
id: this.id,
|
|
181415
|
-
resolve: this.resolve,
|
|
181416
|
-
timeoutMs: this.timeoutMs
|
|
181417
|
-
});
|
|
181418
|
+
}
|
|
181419
|
+
const existingHtml = this.readSlotHtml();
|
|
181420
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(existingHtml && existingHtml.length > 0 ? existingHtml : this.fallbackHtml));
|
|
181418
181421
|
}
|
|
181419
181422
|
ngAfterViewInit() {
|
|
181420
181423
|
if (typeof window === "undefined")
|
|
181421
181424
|
return;
|
|
181422
181425
|
window.addEventListener(SLOT_PATCH_EVENT, this.patchListener);
|
|
181423
|
-
const
|
|
181424
|
-
const existingHtml = slotElement?.innerHTML;
|
|
181426
|
+
const existingHtml = this.readSlotHtml();
|
|
181425
181427
|
if (existingHtml && existingHtml !== this.fallbackHtml) {
|
|
181426
181428
|
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(existingHtml));
|
|
181427
181429
|
this.cdr.markForCheck();
|
|
@@ -181432,6 +181434,10 @@ class StreamSlotComponent {
|
|
|
181432
181434
|
return;
|
|
181433
181435
|
window.removeEventListener(SLOT_PATCH_EVENT, this.patchListener);
|
|
181434
181436
|
}
|
|
181437
|
+
readSlotHtml() {
|
|
181438
|
+
const slotElement = this.hostElement.nativeElement.querySelector(`#slot-${this.id}`);
|
|
181439
|
+
return slotElement?.innerHTML ?? "";
|
|
181440
|
+
}
|
|
181435
181441
|
}
|
|
181436
181442
|
__legacyDecorateClassTS([
|
|
181437
181443
|
Input2(),
|
|
@@ -181459,6 +181465,9 @@ __legacyDecorateClassTS([
|
|
|
181459
181465
|
], StreamSlotComponent.prototype, "timeoutMs", undefined);
|
|
181460
181466
|
StreamSlotComponent = __legacyDecorateClassTS([
|
|
181461
181467
|
Component2({
|
|
181468
|
+
host: {
|
|
181469
|
+
ngSkipHydration: "true"
|
|
181470
|
+
},
|
|
181462
181471
|
changeDetection: ChangeDetectionStrategy.OnPush,
|
|
181463
181472
|
selector: "abs-stream-slot",
|
|
181464
181473
|
standalone: true,
|
|
@@ -181667,5 +181676,5 @@ export {
|
|
|
181667
181676
|
DeferSlotComponent
|
|
181668
181677
|
};
|
|
181669
181678
|
|
|
181670
|
-
//# debugId=
|
|
181679
|
+
//# debugId=0E6655AD7F7AC29D64756E2164756E21
|
|
181671
181680
|
//# sourceMappingURL=index.js.map
|