Skip to content

Commit 508b7ac

Browse files
authored
feat(cdk/table): allow text column to be centered (#24133)
Allows for the text inside a text column to be centered. Fixes #23920.
1 parent 723a821 commit 508b7ac

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/cdk/table/text-column.ts

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -85,7 +85,7 @@ export class CdkTextColumn<T> implements OnDestroy, OnInit {
8585
@Input() dataAccessor: (data: T, name: string) => string;
8686

8787
/** Alignment of the cell values. */
88-
@Input() justify: 'start' | 'end' = 'start';
88+
@Input() justify: 'start' | 'end' | 'center' = 'start';
8989

9090
/** @docs-private */
9191
@ViewChild(CdkColumnDef, {static: true}) columnDef: CdkColumnDef;

tools/public_api_guard/cdk/table.md

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -385,7 +385,7 @@ export class CdkTextColumn<T> implements OnDestroy, OnInit {
385385
dataAccessor: (data: T, name: string) => string;
386386
headerCell: CdkHeaderCellDef;
387387
headerText: string;
388-
justify: 'start' | 'end';
388+
justify: 'start' | 'end' | 'center';
389389
get name(): string;
390390
set name(name: string);
391391
// (undocumented)

0 commit comments

Comments
 (0)