intelica-library-components 1.1.159 → 1.1.160
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.
|
@@ -6164,6 +6164,7 @@ class Shared {
|
|
|
6164
6164
|
});
|
|
6165
6165
|
}
|
|
6166
6166
|
async embedDashboard(command, container, options) {
|
|
6167
|
+
container?.replaceChildren();
|
|
6167
6168
|
const embedUrl = await firstValueFrom(this.getEmbedUrl(command));
|
|
6168
6169
|
await this.createEmbedContext(embedUrl, container, options);
|
|
6169
6170
|
}
|
|
@@ -6216,22 +6217,22 @@ class DashboardQsComponent {
|
|
|
6216
6217
|
});
|
|
6217
6218
|
effect(() => {
|
|
6218
6219
|
const id = this.dashboardId();
|
|
6219
|
-
|
|
6220
|
+
const parameters = this.parameters();
|
|
6220
6221
|
if (!this.viewReady() || !id)
|
|
6221
6222
|
return;
|
|
6222
|
-
this.EmbedDashboard(id);
|
|
6223
|
+
this.EmbedDashboard(id, parameters);
|
|
6223
6224
|
});
|
|
6224
6225
|
}
|
|
6225
6226
|
ngAfterViewInit() {
|
|
6226
6227
|
this.viewReady.set(true);
|
|
6227
6228
|
}
|
|
6228
|
-
async EmbedDashboard(dashboardId) {
|
|
6229
|
+
async EmbedDashboard(dashboardId, parameters) {
|
|
6229
6230
|
const container = this.containers.first?.nativeElement;
|
|
6230
6231
|
if (!container)
|
|
6231
6232
|
return;
|
|
6232
6233
|
this.isLoading.set(true);
|
|
6233
6234
|
try {
|
|
6234
|
-
await this.sharedService.embedDashboard({ dashboardId, parameters
|
|
6235
|
+
await this.sharedService.embedDashboard({ dashboardId, parameters }, container, { height: this.height() ?? `${window.innerHeight - 50}px` });
|
|
6235
6236
|
}
|
|
6236
6237
|
catch (error) {
|
|
6237
6238
|
console.error('Error embedding dashboard:', error);
|