Skip to content

Commit

Permalink
chore: clean up remaining mixed mat/cdk table usages (#18439)
Browse files Browse the repository at this point in the history
A while ago all live examples that were missing Material and CDK tables were cleaned up, but there were a couple of leftovers in the dev apps. These changes clean up that last few places.
  • Loading branch information
crisbeto authored Feb 7, 2020
1 parent f2f78a0 commit a58c725
Show file tree
Hide file tree
Showing 2 changed files with 38 additions and 38 deletions.
66 changes: 33 additions & 33 deletions src/a11y-demo/table/table-a11y.html
Original file line number Diff line number Diff line change
Expand Up @@ -5,20 +5,20 @@ <h2>Basic Table</h2>
<mat-table aria-readonly="true"
[dataSource]="basicDataSource"
aria-label="Users favorite colors and age">
<ng-container cdkColumnDef="name">
<mat-header-cell *cdkHeaderCellDef>Name</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.name}}</mat-cell>
<ng-container matColumnDef="name">
<mat-header-cell *matHeaderCellDef>Name</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.name}}</mat-cell>
</ng-container>
<ng-container cdkColumnDef="color">
<mat-header-cell *cdkHeaderCellDef>Color</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.color}}</mat-cell>
<ng-container matColumnDef="color">
<mat-header-cell *matHeaderCellDef>Color</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.color}}</mat-cell>
</ng-container>
<ng-container cdkColumnDef="age">
<mat-header-cell *cdkHeaderCellDef>Age</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.age}}</mat-cell>
<ng-container matColumnDef="age">
<mat-header-cell *matHeaderCellDef>Age</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.age}}</mat-cell>
</ng-container>
<mat-header-row *cdkHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *cdkRowDef="let row; columns: displayedColumns;"></mat-row>
<mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *matRowDef="let row; columns: displayedColumns;"></mat-row>
</mat-table>
</section>

Expand All @@ -30,20 +30,20 @@ <h2>Sortable Table</h2>
aria-readonly="true"
matSort matSortActive="age"
matSortDirection="asc">
<ng-container cdkColumnDef="name">
<mat-header-cell *cdkHeaderCellDef>Name</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.name}}</mat-cell>
<ng-container matColumnDef="name">
<mat-header-cell *matHeaderCellDef>Name</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.name}}</mat-cell>
</ng-container>
<ng-container cdkColumnDef="color">
<mat-header-cell *cdkHeaderCellDef>Color</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.color}}</mat-cell>
<ng-container matColumnDef="color">
<mat-header-cell *matHeaderCellDef>Color</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.color}}</mat-cell>
</ng-container>
<ng-container cdkColumnDef="age">
<mat-header-cell *cdkHeaderCellDef mat-sort-header>Age</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.age}}</mat-cell>
<ng-container matColumnDef="age">
<mat-header-cell *matHeaderCellDef mat-sort-header>Age</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.age}}</mat-cell>
</ng-container>
<mat-header-row *cdkHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *cdkRowDef="let row; columns: displayedColumns;"></mat-row>
<mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *matRowDef="let row; columns: displayedColumns;"></mat-row>
</mat-table>
</section>

Expand All @@ -53,20 +53,20 @@ <h2>Paginated Table</h2>
<mat-table [dataSource]="paginatedDataSource"
aria-readonly="true"
aria-label="Users favorite colors and age">
<ng-container cdkColumnDef="name">
<mat-header-cell *cdkHeaderCellDef>Name</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.name}}</mat-cell>
<ng-container matColumnDef="name">
<mat-header-cell *matHeaderCellDef>Name</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.name}}</mat-cell>
</ng-container>
<ng-container cdkColumnDef="color">
<mat-header-cell *cdkHeaderCellDef>Color</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.color}}</mat-cell>
<ng-container matColumnDef="color">
<mat-header-cell *matHeaderCellDef>Color</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.color}}</mat-cell>
</ng-container>
<ng-container cdkColumnDef="age">
<mat-header-cell *cdkHeaderCellDef>Age</mat-header-cell>
<mat-cell *cdkCellDef="let row">{{row.age}}</mat-cell>
<ng-container matColumnDef="age">
<mat-header-cell *matHeaderCellDef>Age</mat-header-cell>
<mat-cell *matCellDef="let row">{{row.age}}</mat-cell>
</ng-container>
<mat-header-row *cdkHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *cdkRowDef="let row; columns: displayedColumns;"></mat-row>
<mat-header-row *matHeaderRowDef="displayedColumns"></mat-header-row>
<mat-row *matRowDef="let row; columns: displayedColumns;"></mat-row>
</mat-table>
<mat-paginator #paginator
[length]="6"
Expand Down
10 changes: 5 additions & 5 deletions src/universal-app/kitchen-sink/kitchen-sink.html
Original file line number Diff line number Diff line change
Expand Up @@ -293,13 +293,13 @@ <h2>CDK Table</h2>
<h2>Material Table</h2>

<mat-table [dataSource]="tableDataSource">
<ng-container cdkColumnDef="userId">
<mat-header-cell *cdkHeaderCellDef>ID</mat-header-cell>
<mat-cell *cdkCellDef="let row"> {{row.userId}} </mat-cell>
<ng-container matColumnDef="userId">
<mat-header-cell *matHeaderCellDef>ID</mat-header-cell>
<mat-cell *matCellDef="let row"> {{row.userId}} </mat-cell>
</ng-container>

<mat-header-row *cdkHeaderRowDef="tableColumns"></mat-header-row>
<mat-row *cdkRowDef="let row; columns: tableColumns;"></mat-row>
<mat-header-row *matHeaderRowDef="tableColumns"></mat-header-row>
<mat-row *matRowDef="let row; columns: tableColumns;"></mat-row>
</mat-table>

<h2>Native table with sticky header and footer</h2>
Expand Down

0 comments on commit a58c725

Please sign in to comment.