@absolutejs/absolute 0.19.0-beta.407 → 0.19.0-beta.409
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 +38 -8
- package/dist/angular/browser.js.map +3 -3
- package/dist/angular/components/stream-slot.component.js +29 -6
- package/dist/angular/index.js +42 -8
- package/dist/angular/index.js.map +4 -4
- package/dist/client/index.js +5 -1
- package/dist/client/index.js.map +3 -3
- package/dist/index.js +5 -1
- package/dist/index.js.map +3 -3
- package/dist/react/index.js +5 -1
- package/dist/react/index.js.map +3 -3
- package/dist/src/angular/components/stream-slot.component.d.ts +7 -2
- package/dist/svelte/index.js +5 -1
- package/dist/svelte/index.js.map +3 -3
- package/dist/vue/index.js +5 -1
- package/dist/vue/index.js.map +3 -3
- package/package.json +1 -1
package/dist/angular/browser.js
CHANGED
|
@@ -9551,17 +9551,32 @@ var IslandStore = IslandStoreImpl;
|
|
|
9551
9551
|
import { Component as Component3, computed, input } from "@angular/core";
|
|
9552
9552
|
|
|
9553
9553
|
// src/angular/components/stream-slot.component.ts
|
|
9554
|
-
import {
|
|
9554
|
+
import {
|
|
9555
|
+
Component as Component2,
|
|
9556
|
+
ElementRef as ElementRef2,
|
|
9557
|
+
Input as Input2,
|
|
9558
|
+
inject,
|
|
9559
|
+
signal
|
|
9560
|
+
} from "@angular/core";
|
|
9555
9561
|
import { DomSanitizer } from "@angular/platform-browser";
|
|
9562
|
+
var SLOT_PATCH_EVENT = "absolutejs:slot-patch";
|
|
9563
|
+
|
|
9556
9564
|
class StreamSlotComponent {
|
|
9557
9565
|
constructor() {
|
|
9558
9566
|
this.fallbackHtml = "";
|
|
9559
9567
|
}
|
|
9560
9568
|
sanitizer = inject(DomSanitizer);
|
|
9561
|
-
|
|
9562
|
-
|
|
9563
|
-
|
|
9569
|
+
hostElement = inject(ElementRef2);
|
|
9570
|
+
patchListener = (event) => {
|
|
9571
|
+
const detail = event.detail;
|
|
9572
|
+
if (!detail || detail.id !== this.id || typeof detail.html !== "string") {
|
|
9573
|
+
return;
|
|
9574
|
+
}
|
|
9575
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(detail.html));
|
|
9576
|
+
};
|
|
9577
|
+
currentHtml = signal("");
|
|
9564
9578
|
ngOnInit() {
|
|
9579
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(this.fallbackHtml));
|
|
9565
9580
|
if (typeof window !== "undefined")
|
|
9566
9581
|
return;
|
|
9567
9582
|
registerStreamingSlot({
|
|
@@ -9572,6 +9587,21 @@ class StreamSlotComponent {
|
|
|
9572
9587
|
timeoutMs: this.timeoutMs
|
|
9573
9588
|
});
|
|
9574
9589
|
}
|
|
9590
|
+
ngAfterViewInit() {
|
|
9591
|
+
if (typeof window === "undefined")
|
|
9592
|
+
return;
|
|
9593
|
+
window.addEventListener(SLOT_PATCH_EVENT, this.patchListener);
|
|
9594
|
+
const slotElement = this.hostElement.nativeElement.querySelector(`#slot-${this.id}`);
|
|
9595
|
+
const existingHtml = slotElement?.innerHTML;
|
|
9596
|
+
if (existingHtml && existingHtml !== this.fallbackHtml) {
|
|
9597
|
+
this.currentHtml.set(this.sanitizer.bypassSecurityTrustHtml(existingHtml));
|
|
9598
|
+
}
|
|
9599
|
+
}
|
|
9600
|
+
ngOnDestroy() {
|
|
9601
|
+
if (typeof window === "undefined")
|
|
9602
|
+
return;
|
|
9603
|
+
window.removeEventListener(SLOT_PATCH_EVENT, this.patchListener);
|
|
9604
|
+
}
|
|
9575
9605
|
}
|
|
9576
9606
|
__legacyDecorateClassTS([
|
|
9577
9607
|
Input2(),
|
|
@@ -9606,7 +9636,7 @@ StreamSlotComponent = __legacyDecorateClassTS([
|
|
|
9606
9636
|
[attr.id]="'slot-' + id"
|
|
9607
9637
|
[attr.class]="className"
|
|
9608
9638
|
data-absolute-slot="true"
|
|
9609
|
-
[innerHTML]="
|
|
9639
|
+
[innerHTML]="currentHtml()"
|
|
9610
9640
|
></div>
|
|
9611
9641
|
`
|
|
9612
9642
|
})
|
|
@@ -9650,7 +9680,7 @@ DeferSlotComponent = __legacyDecorateClassTS([
|
|
|
9650
9680
|
], DeferSlotComponent);
|
|
9651
9681
|
// src/angular/components/image.component.ts
|
|
9652
9682
|
init_imageProcessing();
|
|
9653
|
-
import { Component as Component4, computed as computed2, input as input2, signal } from "@angular/core";
|
|
9683
|
+
import { Component as Component4, computed as computed2, input as input2, signal as signal2 } from "@angular/core";
|
|
9654
9684
|
import { NgStyle } from "@angular/common";
|
|
9655
9685
|
var resolveBlurBg = (placeholderValue, blurDataUrl) => {
|
|
9656
9686
|
if (typeof placeholderValue === "string" && placeholderValue !== "blur" && placeholderValue.startsWith("data:")) {
|
|
@@ -9683,7 +9713,7 @@ class ImageComponent {
|
|
|
9683
9713
|
style = input2();
|
|
9684
9714
|
unoptimized = input2(false);
|
|
9685
9715
|
width = input2();
|
|
9686
|
-
blurRemoved =
|
|
9716
|
+
blurRemoved = signal2(false);
|
|
9687
9717
|
resolvedSrc = computed2(() => {
|
|
9688
9718
|
const override = this.overrideSrc();
|
|
9689
9719
|
if (override)
|
|
@@ -9806,5 +9836,5 @@ export {
|
|
|
9806
9836
|
DeferSlotComponent
|
|
9807
9837
|
};
|
|
9808
9838
|
|
|
9809
|
-
//# debugId=
|
|
9839
|
+
//# debugId=567E71B8705D774464756E2164756E21
|
|
9810
9840
|
//# sourceMappingURL=browser.js.map
|