Skip to content

Commit 21247f9

Browse files
feat: adding loading config functionality to table view toggle widget (#1267)
1 parent c601819 commit 21247f9

File tree

3 files changed

+10
-2
lines changed

3 files changed

+10
-2
lines changed

projects/observability/src/shared/dashboard/widgets/table/table-widget-base.model.ts

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -195,4 +195,8 @@ export abstract class TableWidgetBaseModel extends BaseModel {
195195
public isResizable(): boolean {
196196
return this.resizable;
197197
}
198+
199+
public getLoadingConfig(): LoadAsyncConfig | undefined {
200+
return this.loadingConfig;
201+
}
198202
}

projects/observability/src/shared/dashboard/widgets/table/table-widget-renderer.component.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -97,7 +97,7 @@ import { TableWidgetModel } from './table-widget.model';
9797
[selectionMode]="this.model.getSelectionMode()"
9898
[display]="this.model.style"
9999
[data]="this.data$ | async"
100-
[loadingConfig]="this.model.loadingConfig"
100+
[loadingConfig]="this.model.getLoadingConfig()"
101101
[filters]="this.combinedFilters$ | async"
102102
[queryProperties]="this.queryProperties$ | async"
103103
[pageable]="this.api.model.isPageable()"

projects/observability/src/shared/dashboard/widgets/table/table-widget-view-toggle.model.ts

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,4 +1,4 @@
1-
import { TableDataSource, TableRow, TableSelectionMode } from '@hypertrace/components';
1+
import { LoadAsyncConfig, TableDataSource, TableRow, TableSelectionMode } from '@hypertrace/components';
22
import { ArrayPropertyTypeInstance } from '@hypertrace/dashboards';
33
import { ARRAY_PROPERTY, Model, ModelApi, ModelOnInit, ModelProperty, ModelPropertyType } from '@hypertrace/hyperdash';
44
import { ModelInject, MODEL_API } from '@hypertrace/hyperdash-angular';
@@ -118,4 +118,8 @@ export class TableWidgetViewToggleModel extends TableWidgetModel implements Mode
118118
public getSelectControlOptions(): TableWidgetControlSelectOptionModel[] {
119119
return this.delegateModel?.getSelectControlOptions() ?? this.selectOptions;
120120
}
121+
122+
public getLoadingConfig(): LoadAsyncConfig | undefined {
123+
return this.delegateModel?.getLoadingConfig();
124+
}
121125
}

0 commit comments

Comments
 (0)