@praxisui/core 9.0.28 → 9.0.29
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.
|
@@ -1,8 +1,8 @@
|
|
|
1
1
|
{
|
|
2
2
|
"schemaVersion": "1.0.0",
|
|
3
|
-
"generatedAt": "2026-08-
|
|
3
|
+
"generatedAt": "2026-08-28T12:49:04.203Z",
|
|
4
4
|
"packageName": "@praxisui/core",
|
|
5
|
-
"packageVersion": "9.0.
|
|
5
|
+
"packageVersion": "9.0.29",
|
|
6
6
|
"sourceRegistry": "praxis-component-registry-ingestion",
|
|
7
7
|
"sourceRegistryVersion": "1.0.0",
|
|
8
8
|
"componentCount": 4,
|
|
@@ -1,5 +1,5 @@
|
|
|
1
1
|
import * as i0 from '@angular/core';
|
|
2
|
-
import { Component, InjectionToken, Injectable, inject, Inject, Optional, SkipSelf, makeEnvironmentProviders, APP_INITIALIZER, signal, computed, DestroyRef, ENVIRONMENT_INITIALIZER, ErrorHandler, Input, Directive, input, booleanAttribute, ChangeDetectionStrategy, EventEmitter, Output, SecurityContext, ViewContainerRef, SimpleChange, ContentChild, HostBinding, Injector, ElementRef, ChangeDetectorRef, HostListener, ViewChildren, ViewChild, output, effect } from '@angular/core';
|
|
2
|
+
import { Component, InjectionToken, Injectable, inject, Inject, Optional, SkipSelf, makeEnvironmentProviders, APP_INITIALIZER, signal, computed, DestroyRef, ENVIRONMENT_INITIALIZER, ErrorHandler, Input, Directive, input, booleanAttribute, ChangeDetectionStrategy, EventEmitter, Output, SecurityContext, ViewContainerRef, SimpleChange, ContentChild, HostBinding, Injector, ElementRef, ChangeDetectorRef, afterNextRender, HostListener, ViewChildren, ViewChild, output, effect } from '@angular/core';
|
|
3
3
|
import * as i1 from '@angular/common/http';
|
|
4
4
|
import { HttpHeaders, HttpClient, HttpParams, HttpResponse, HttpContextToken, HTTP_INTERCEPTORS, withInterceptors } from '@angular/common/http';
|
|
5
5
|
import { of, defer, throwError, from, EMPTY, BehaviorSubject, firstValueFrom, Subject, finalize as finalize$1, shareReplay as shareReplay$1, map as map$1, switchMap as switchMap$1, catchError as catchError$1, forkJoin } from 'rxjs';
|
|
@@ -37593,7 +37593,7 @@ class DynamicWidgetPageComponent {
|
|
|
37593
37593
|
widgetLoaders;
|
|
37594
37594
|
constructor() {
|
|
37595
37595
|
this.registerRuntimeComponentObservationProvider();
|
|
37596
|
-
this.observeHostWidth();
|
|
37596
|
+
afterNextRender({ read: () => this.observeHostWidth() });
|
|
37597
37597
|
}
|
|
37598
37598
|
ngOnDestroy() {
|
|
37599
37599
|
this.destroyed = true;
|
|
@@ -39875,6 +39875,11 @@ class DynamicWidgetPageComponent {
|
|
|
39875
39875
|
onWindowResize() {
|
|
39876
39876
|
if (!this.pageDefinition)
|
|
39877
39877
|
return;
|
|
39878
|
+
const measuredWidth = this.measureHostWidth();
|
|
39879
|
+
if (this.updateContainerWidth(measuredWidth))
|
|
39880
|
+
return;
|
|
39881
|
+
if (this.containerWidth)
|
|
39882
|
+
return;
|
|
39878
39883
|
this.applyResponsivePresentation(this.pageDefinition, this.pageDefinition.widgets || [], this.pageRuntime);
|
|
39879
39884
|
}
|
|
39880
39885
|
onCanvasPointerMove(event) {
|
|
@@ -40160,25 +40165,35 @@ class DynamicWidgetPageComponent {
|
|
|
40160
40165
|
: fallback;
|
|
40161
40166
|
}
|
|
40162
40167
|
observeHostWidth() {
|
|
40168
|
+
if (this.destroyed)
|
|
40169
|
+
return;
|
|
40170
|
+
this.updateContainerWidth(this.measureHostWidth());
|
|
40163
40171
|
const ResizeObserverCtor = globalThis.ResizeObserver;
|
|
40164
40172
|
if (typeof ResizeObserverCtor !== 'function') {
|
|
40165
40173
|
return;
|
|
40166
40174
|
}
|
|
40167
40175
|
this.hostResizeObserver = new ResizeObserverCtor((entries) => {
|
|
40168
|
-
|
|
40169
|
-
if (!Number.isFinite(width)
|
|
40170
|
-
|| width <= 0
|
|
40171
|
-
|| Math.abs(width - (this.containerWidth || 0)) < 0.5) {
|
|
40172
|
-
return;
|
|
40173
|
-
}
|
|
40174
|
-
this.containerWidth = width;
|
|
40175
|
-
if (this.pageDefinition) {
|
|
40176
|
-
this.applyResponsivePresentation(this.pageDefinition, this.pageDefinition.widgets || [], this.pageRuntime);
|
|
40177
|
-
this.changeDetector.markForCheck();
|
|
40178
|
-
}
|
|
40176
|
+
this.updateContainerWidth(entries[0]?.contentRect.width);
|
|
40179
40177
|
});
|
|
40180
40178
|
this.hostResizeObserver.observe(this.hostElement.nativeElement);
|
|
40181
40179
|
}
|
|
40180
|
+
measureHostWidth() {
|
|
40181
|
+
return this.hostElement.nativeElement.getBoundingClientRect().width;
|
|
40182
|
+
}
|
|
40183
|
+
updateContainerWidth(width) {
|
|
40184
|
+
if (!Number.isFinite(width)
|
|
40185
|
+
|| !width
|
|
40186
|
+
|| width <= 0
|
|
40187
|
+
|| Math.abs(width - (this.containerWidth || 0)) < 0.5) {
|
|
40188
|
+
return false;
|
|
40189
|
+
}
|
|
40190
|
+
this.containerWidth = width;
|
|
40191
|
+
if (this.pageDefinition) {
|
|
40192
|
+
this.applyResponsivePresentation(this.pageDefinition, this.pageDefinition.widgets || [], this.pageRuntime);
|
|
40193
|
+
this.changeDetector.markForCheck();
|
|
40194
|
+
}
|
|
40195
|
+
return true;
|
|
40196
|
+
}
|
|
40182
40197
|
isCanvasMode() {
|
|
40183
40198
|
return !!this.canvas;
|
|
40184
40199
|
}
|
package/package.json
CHANGED
package/types/praxisui-core.d.ts
CHANGED
|
@@ -16621,6 +16621,8 @@ declare class DynamicWidgetPageComponent implements OnChanges, OnDestroy {
|
|
|
16621
16621
|
private resolveDeviceKind;
|
|
16622
16622
|
private resolveViewportWidth;
|
|
16623
16623
|
private observeHostWidth;
|
|
16624
|
+
private measureHostWidth;
|
|
16625
|
+
private updateContainerWidth;
|
|
16624
16626
|
isCanvasMode(): boolean;
|
|
16625
16627
|
shouldAutoWireOutputs(widget: WidgetInstance | RenderedWidgetInstance): boolean;
|
|
16626
16628
|
private hasCompositionOutputLinks;
|