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