Skip to content

Commit e3825c8

Browse files
authored
refactor(cdk/table): expose data source type (#24782)
Exposes the `CdkTableDataSourceInput` type since it can be useful for people implementing their own tables. Fixes #24518.
1 parent a55a836 commit e3825c8

File tree

2 files changed

+5
-5
lines changed

2 files changed

+5
-5
lines changed

src/cdk/table/table.ts

Lines changed: 2 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -101,11 +101,8 @@ export interface RowOutlet {
101101
viewContainer: ViewContainerRef;
102102
}
103103

104-
/**
105-
* Union of the types that can be set as the data source for a `CdkTable`.
106-
* @docs-private
107-
*/
108-
type CdkTableDataSourceInput<T> = readonly T[] | DataSource<T> | Observable<readonly T[]>;
104+
/** Possible types that can be set as the data source for a `CdkTable`. */
105+
export type CdkTableDataSourceInput<T> = readonly T[] | DataSource<T> | Observable<readonly T[]>;
109106

110107
/**
111108
* Provides a handle for the table to grab the view container's ng-container to insert data rows.

tools/public_api_guard/cdk/table.md

Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -366,6 +366,9 @@ export class CdkTable<T> implements AfterContentChecked, CollectionViewer, OnDes
366366
static ɵfac: i0.ɵɵFactoryDeclaration<CdkTable<any>, [null, null, null, { attribute: "role"; }, { optional: true; }, null, null, null, null, null, { optional: true; skipSelf: true; }, { optional: true; }]>;
367367
}
368368

369+
// @public
370+
export type CdkTableDataSourceInput<T> = readonly T[] | DataSource<T> | Observable<readonly T[]>;
371+
369372
// @public (undocumented)
370373
export class CdkTableModule {
371374
// (undocumented)

0 commit comments

Comments
 (0)